[vlc-commits] qt4: fix skins2 crash after exiting the preferences dialog
Erwan Tulou
git at videolan.org
Thu Jan 20 16:23:28 CET 2011
vlc/vlc-1.1 | branch: master | Erwan Tulou <erwan10 at videolan.org> | Fri Dec 10 19:44:45 2010 +0100| [e776e115f68338d8130b3988b5e0f0c304fdff01] | committer: Erwan Tulou
qt4: fix skins2 crash after exiting the preferences dialog
This fixes a regression brought by 7f485998dd63c9685f0a470439c9b2ea127ef5c5
On skins2(tested on Linux), open and close the preferences dialog leads to a
crash, because the whole qt4 thread terminates unexpectedly.
This is due to setQuitOnLastWindowClosed set to true. As a dialog provider,
qt4 doesn't run any windows, and therefore just closing the preferences
dialog box (via accept() or reject()) signals the qt4 thread to quit.
(cherry picked from commit 3326e7ef0e333e7a1aa6419c4547703dcbd23618)
> http://git.videolan.org/gitweb.cgi/vlc/vlc-1.1.git/?a=commit;h=e776e115f68338d8130b3988b5e0f0c304fdff01
---
modules/gui/qt4/qt4.cpp | 5 ++++-
1 files changed, 4 insertions(+), 1 deletions(-)
diff --git a/modules/gui/qt4/qt4.cpp b/modules/gui/qt4/qt4.cpp
index aa7a182..f55a6dc 100644
--- a/modules/gui/qt4/qt4.cpp
+++ b/modules/gui/qt4/qt4.cpp
@@ -454,7 +454,10 @@ static void *Thread( void *obj )
vlc_sem_post (&ready);
/* Last settings */
- app.setQuitOnLastWindowClosed( true );
+ if( p_intf->p_sys->b_isDialogProvider )
+ app.setQuitOnLastWindowClosed( false );
+ else
+ app.setQuitOnLastWindowClosed( true );
/* Retrieve last known path used in file browsing */
p_intf->p_sys->filepath =
More information about the vlc-commits
mailing list