[vlc-devel] commit: qt4: two more places where uri-encoded mrl are required ( Erwan Tulou )

git version control git at videolan.org
Wed Aug 26 13:06:17 CEST 2009


vlc | branch: master | Erwan Tulou <erwan10 at videolan.org> | Wed Aug 26 12:57:55 2009 +0200| [0b2e85503a319bc912beb20b1027df03a2c360a8] | committer: Erwan Tulou 

qt4: two more places where uri-encoded mrl are required

> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=0b2e85503a319bc912beb20b1027df03a2c360a8
---

 modules/gui/qt4/dialogs_provider.cpp |    4 +++-
 modules/gui/qt4/main_interface.cpp   |    4 +++-
 2 files changed, 6 insertions(+), 2 deletions(-)

diff --git a/modules/gui/qt4/dialogs_provider.cpp b/modules/gui/qt4/dialogs_provider.cpp
index 91ab27d..40b8513 100644
--- a/modules/gui/qt4/dialogs_provider.cpp
+++ b/modules/gui/qt4/dialogs_provider.cpp
@@ -701,8 +701,10 @@ void DialogsProvider::SDMenuAction( const QString& data )
  **/
 void DialogsProvider::playMRL( const QString &mrl )
 {
-    playlist_Add( THEPL, qtu( mrl ) , NULL,
+    char* psz_uri = make_URI( qtu(mrl) );
+    playlist_Add( THEPL, psz_uri, NULL,
            PLAYLIST_APPEND | PLAYLIST_GO , PLAYLIST_END, true, false );
+    free( psz_uri );
 
     RecentsMRL::getInstance( p_intf )->addRecent( mrl );
 }
diff --git a/modules/gui/qt4/main_interface.cpp b/modules/gui/qt4/main_interface.cpp
index 9ec5588..1807f3c 100644
--- a/modules/gui/qt4/main_interface.cpp
+++ b/modules/gui/qt4/main_interface.cpp
@@ -1256,9 +1256,11 @@ void MainInterface::dropEventPlay( QDropEvent *event, bool b_play )
         QString s = toNativeSeparators( url.toLocalFile() );
 
         if( s.length() > 0 ) {
-            playlist_Add( THEPL, qtu(s), NULL,
+            char* psz_uri = make_URI( qtu(s) );
+            playlist_Add( THEPL, psz_uri, NULL,
                           PLAYLIST_APPEND | (first ? PLAYLIST_GO: PLAYLIST_PREPARSE),
                           PLAYLIST_END, true, pl_Unlocked );
+            free( psz_uri );
             first = false;
             RecentsMRL::getInstance( p_intf )->addRecent( s );
         }




More information about the vlc-devel mailing list