Skip to content

Commit

Permalink
Fix TLS on Windows.
Browse files Browse the repository at this point in the history
  • Loading branch information
iwalton3 committed Apr 6, 2021
1 parent 7ab71d0 commit a7a2491
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions src/player/PlayerComponent.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -128,8 +128,6 @@ bool PlayerComponent::componentInitialize()
// See: https://github.com/plexinc/plex-media-player/issues/736
mpv::qt::set_property(m_mpv, "cache-seek-min", 5000);

mpv::qt::set_property(m_mpv, "tls-verify", "yes");

#if !defined(Q_OS_WIN) && !defined(Q_OS_MAC)
QList<QByteArray> list;
list << "/etc/ssl/certs/ca-certificates.crt"
Expand All @@ -147,13 +145,17 @@ bool PlayerComponent::componentInitialize()
{
if (access(path.data(), R_OK) == 0) {
mpv::qt::set_property(m_mpv, "tls-ca-file", path.data());
mpv::qt::set_property(m_mpv, "tls-verify", "yes");
success = true;
break;
}
}

if (!success)
throw FatalException(tr("Failed to locate CA bundle."));
#else
// We need to not use Shinchiro's personal CA file...
mpv::qt::set_property(m_mpv, "tls-ca-file", "");
#endif

// Apply some low-memory settings on RPI, which is relatively memory-constrained.
Expand Down

0 comments on commit a7a2491

Please sign in to comment.