]> git.sesse.net Git - vlc/commitdiff
Qt/Sout: avoid a possible crash
authorJean-Baptiste Kempf <jb@videolan.org>
Sat, 4 Sep 2010 16:19:45 +0000 (18:19 +0200)
committerJean-Baptiste Kempf <jb@videolan.org>
Sat, 4 Sep 2010 16:34:36 +0000 (18:34 +0200)
modules/gui/qt4/dialogs/sout.cpp

index 1f512f8d48db41c82d4158beaecbedff1232125b..3a6a53f2228e2b4aabdc6763234b9bca7c230ab0 100644 (file)
@@ -224,9 +224,12 @@ void SoutDialog::updateMRL()
     for( int i = 1; i < ui.destTab->count(); i++ )
     {
         VirtualDestBox *vdb = qobject_cast<VirtualDestBox *>(ui.destTab->widget( i ));
-        QString tempMRL = vdb->getMRL( qs_mux );
+        if( !vdb )
+            continue;
 
+        QString tempMRL = vdb->getMRL( qs_mux );
         if( tempMRL.isEmpty() ) continue;
+
         if( multi )
             smrl.option( "dst", tempMRL );
         else