]> git.sesse.net Git - vlc/blobdiff - modules/demux/playlist/asx.c
IFO: fix non-ASCII paths
[vlc] / modules / demux / playlist / asx.c
index 5099c9a8cccda6f848bcbc2f711481c006b951ab..02e445b3bf31cc1dd367339538f550ec2a965d18 100644 (file)
@@ -211,7 +211,7 @@ int Import_ASX( vlc_object_t *p_this )
     p_demux->p_sys->i_data_len = -1;
     p_demux->p_sys->b_utf8 = false;
     p_demux->p_sys->b_skip_ads =
-        var_InheritInteger( p_demux, "playlist-skip-ads" );
+        var_InheritBool( p_demux, "playlist-skip-ads" );
 
     return VLC_SUCCESS;
 }
@@ -473,7 +473,6 @@ static int Demux( demux_t *p_demux )
                             input_item_t *p_input;
                             p_input = input_item_New( p_demux, psz_string, psz_title_asx );
                             input_item_CopyOptions( p_current_input, p_input );
-                            input_item_AddSubItem( p_current_input, p_input );
                             input_item_node_AppendItem( p_subitems, p_input );
                             vlc_gc_decref( p_input );
                             free( psz_string );
@@ -569,10 +568,9 @@ static int Demux( demux_t *p_demux )
                         {
                             if( uniq_entry_ad_backup != NULL )
                             {
-                                uniq_entry_ad_backup = NULL;
                                 vlc_gc_decref( uniq_entry_ad_backup );
+                                uniq_entry_ad_backup = NULL;
                             }
-                            input_item_AddSubItem( p_current_input, p_entry );
                             input_item_node_AppendItem( p_subitems, p_entry );
                             vlc_gc_decref( p_entry );
                         }
@@ -650,7 +648,6 @@ static int Demux( demux_t *p_demux )
                                 if( psz_copyright_entry ) input_item_SetCopyright( p_entry, psz_copyright_entry );
                                 if( psz_moreinfo_entry ) input_item_SetURL( p_entry, psz_moreinfo_entry );
                                 if( psz_abstract_entry ) input_item_SetDescription( p_entry, psz_abstract_entry );
-                                input_item_AddSubItem( p_current_input, p_entry );
                                 input_item_node_AppendItem( p_subitems, p_entry );
                                 vlc_gc_decref( p_entry );
                             }
@@ -754,7 +751,6 @@ static int Demux( demux_t *p_demux )
         {
             msg_Dbg( p_demux, "added unique entry even if ad");
             /* If ASX contains a unique entry, we add it, it is probably not an ad */
-            input_item_AddSubItem( p_current_input, uniq_entry_ad_backup );
             input_item_node_AppendItem( p_subitems, uniq_entry_ad_backup );
             vlc_gc_decref( uniq_entry_ad_backup);
         }
@@ -768,8 +764,7 @@ static int Demux( demux_t *p_demux )
 #endif
     }
 
-    input_item_AddSubItemTree( p_subitems );
-    input_item_node_Delete( p_subitems );
+    input_item_node_PostAndDelete( p_subitems );
 
     vlc_gc_decref(p_current_input);
     return 0; /* Needed for correct operation of go back */