[vlc-devel] commit: demux/playlist: Don't use playlist_t code. (Pierre d'Herbemont )

git version control git at videolan.org
Sat Jun 14 17:34:34 CEST 2008


vlc | branch: master | Pierre d'Herbemont <pdherbemont at videolan.org> | Sat Jun 14 17:12:13 2008 +0200| [8589b24945ea0e4f049ab0d32de0fab8a480e9bd]

demux/playlist: Don't use playlist_t code.

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

 modules/demux/playlist/playlist.c |    1 -
 modules/demux/playlist/pls.c      |    4 ++--
 modules/demux/playlist/podcast.c  |    5 +----
 modules/demux/playlist/qtl.c      |   11 ++---------
 4 files changed, 5 insertions(+), 16 deletions(-)

diff --git a/modules/demux/playlist/playlist.c b/modules/demux/playlist/playlist.c
index 5009a61..657e1fc 100644
--- a/modules/demux/playlist/playlist.c
+++ b/modules/demux/playlist/playlist.c
@@ -31,7 +31,6 @@
 #include <vlc_common.h>
 #include <vlc_plugin.h>
 #include <vlc_demux.h>
-#include <vlc_playlist.h>
 
 #include "playlist.h"
 
diff --git a/modules/demux/playlist/pls.c b/modules/demux/playlist/pls.c
index bd382b6..3a8d6f2 100644
--- a/modules/demux/playlist/pls.c
+++ b/modules/demux/playlist/pls.c
@@ -159,7 +159,7 @@ static int Demux( demux_t *p_demux )
         {
             if( psz_mrl )
             {
-                p_input = input_ItemNewExt( p_playlist, psz_mrl, psz_name,
+                p_input = input_ItemNewExt( p_demux, psz_mrl, psz_name,
                                             0, NULL, -1 );
                 input_ItemCopyOptions( p_current_input, p_input );
                 input_ItemAddSubItem( p_current_input, p_input );
@@ -215,7 +215,7 @@ static int Demux( demux_t *p_demux )
     /* Add last object */
     if( psz_mrl )
     {
-        p_input = input_ItemNewExt( p_playlist, psz_mrl, psz_name,0, NULL, -1 );
+        p_input = input_ItemNewExt( p_demux, psz_mrl, psz_name,0, NULL, -1 );
         input_ItemCopyOptions( p_current_input, p_input );
         input_ItemAddSubItem( p_current_input, p_input );
         vlc_gc_decref( p_input );
diff --git a/modules/demux/playlist/podcast.c b/modules/demux/playlist/podcast.c
index c035f10..31306f4 100644
--- a/modules/demux/playlist/podcast.c
+++ b/modules/demux/playlist/podcast.c
@@ -37,7 +37,6 @@
 struct demux_sys_t
 {
     char *psz_prefix;
-    playlist_t *p_playlist;
     xml_t *p_xml;
     xml_reader_t *p_xml_reader;
 };
@@ -60,7 +59,6 @@ int Import_podcast( vlc_object_t *p_this )
 
     STANDARD_DEMUX_INIT_MSG( "using podcast reader" );
     p_demux->p_sys->psz_prefix = FindPrefix( p_demux );
-    p_demux->p_sys->p_playlist = NULL;
     p_demux->p_sys->p_xml = NULL;
     p_demux->p_sys->p_xml_reader = NULL;
 
@@ -76,7 +74,6 @@ void Close_podcast( vlc_object_t *p_this )
     demux_sys_t *p_sys = p_demux->p_sys;
 
     free( p_sys->psz_prefix );
-    if( p_sys->p_playlist ) vlc_object_release( p_sys->p_playlist );
     if( p_sys->p_xml_reader ) xml_ReaderDelete( p_sys->p_xml, p_sys->p_xml_reader );
     if( p_sys->p_xml ) xml_Delete( p_sys->p_xml );
     free( p_sys );
@@ -275,7 +272,7 @@ static int Demux( demux_t *p_demux )
                         msg_Err( p_demux, "invalid XML (no enclosure markup)" );
                         return -1;
                     }
-                    p_input = input_ItemNewExt( p_playlist, psz_item_mrl,
+                    p_input = input_ItemNewExt( p_demux, psz_item_mrl,
                                                 psz_item_name, 0, NULL, -1 );
                     if( p_input == NULL ) break;
 #define ADD_INFO( info, field ) \
diff --git a/modules/demux/playlist/qtl.c b/modules/demux/playlist/qtl.c
index de90f20..e1585c6 100644
--- a/modules/demux/playlist/qtl.c
+++ b/modules/demux/playlist/qtl.c
@@ -60,7 +60,6 @@ volume - 0 (mute) - 100 (max)
 
 struct demux_sys_t
 {
-    playlist_t *p_playlist;
     input_item_t *p_current_input;
 
     xml_t *p_xml;
@@ -90,7 +89,6 @@ static int Control( demux_t *p_demux, int i_query, va_list args );
 int Import_QTL( vlc_object_t *p_this )
 {
     DEMUX_BY_EXTENSION_MSG( ".qtl", "using QuickTime Media Link reader" );
-    p_demux->p_sys->p_playlist = NULL;
     p_demux->p_sys->p_xml = NULL;
     p_demux->p_sys->p_xml_reader = NULL;
     return VLC_SUCCESS;
@@ -104,8 +102,6 @@ void Close_QTL( vlc_object_t *p_this )
     demux_t *p_demux = (demux_t *)p_this;
     demux_sys_t *p_sys = p_demux->p_sys;
 
-    if( p_sys->p_playlist )
-        vlc_object_release( p_sys->p_playlist );
     if( p_sys->p_xml_reader )
         xml_ReaderDelete( p_sys->p_xml, p_sys->p_xml_reader );
     if( p_sys->p_xml )
@@ -139,7 +135,6 @@ static int Demux( demux_t *p_demux )
 
     INIT_PLAYLIST_STUFF;
 
-    p_sys->p_playlist = p_playlist;
     p_sys->p_current_input = p_current_input;
 
     p_xml = p_sys->p_xml = xml_Create( p_demux );
@@ -354,7 +349,7 @@ static int Demux( demux_t *p_demux )
     }
     else
     {
-        p_input = input_ItemNewExt( p_sys->p_playlist,
+        p_input = input_ItemNewExt( p_demux,
                                 psz_src, psz_moviename, 0, NULL, -1 );
 #define SADD_INFO( type, field ) if( field ) { input_ItemAddInfo( \
                     p_input, "QuickTime Media Link", _(type), "%s", field ) ; }
@@ -364,7 +359,7 @@ static int Demux( demux_t *p_demux )
         vlc_gc_decref( p_input );
         if( psz_qtnext )
         {
-            p_input = input_ItemNewExt( p_sys->p_playlist,
+            p_input = input_ItemNewExt( p_demux,
                                         psz_qtnext, NULL, 0, NULL, -1 );
             input_ItemAddSubItem( p_current_input, p_input );
             vlc_gc_decref( p_input );
@@ -373,8 +368,6 @@ static int Demux( demux_t *p_demux )
 
     HANDLE_PLAY_AND_RELEASE;
 
-    p_sys->p_playlist = NULL;
-
     free( psz_href );
     free( psz_moviename );
     free( psz_qtnext );




More information about the vlc-devel mailing list