Skip to content
Extraits de code Groupes Projets
Vérifiée Valider aab9f08b rédigé par Kubat's avatar Kubat
Parcourir les fichiers

FIX: Try to minimize the segv thing when quiting and leaking MPV

parent bcfcba8c
Aucune branche associée trouvée
Aucune étiquette associée trouvée
1 requête de fusion!27Draft: Fix mpv deadlock on quit main window
...@@ -107,6 +107,14 @@ MpvContainer::~MpvContainer() noexcept ...@@ -107,6 +107,14 @@ MpvContainer::~MpvContainer() noexcept
logWarning() << "The main window was already destroyed, " logWarning() << "The main window was already destroyed, "
"don't destroy MPV and let it leak, " "don't destroy MPV and let it leak, "
"the OS will collect the garbage."; "the OS will collect the garbage.";
if (mpv) {
asyncCommand(AsyncCmdType::None, { "quit", nullptr });
registerMpvTimeCallback(nullptr);
registerMpvDurationCallback(nullptr);
asyncCommand(AsyncCmdType::None, { "quit", nullptr });
mpv = nullptr; // Stop all other callbacks here
isMpvAlreadyInitialized = false; // De-init
}
} }
} }
......
0% Chargement en cours ou .
You are about to add 0 people to the discussion. Proceed with caution.
Veuillez vous inscrire ou vous pour commenter