]> git.sesse.net Git - vlc/blobdiff - src/input/input.c
Use var_Inherit* instead of var_CreateGet*.
[vlc] / src / input / input.c
index af7137fa230d490c1a4629aba5d91ed99fc465df..35da58bd31014e589b6593654d4653b3310b4210 100644 (file)
@@ -53,6 +53,7 @@
 #include <vlc_charset.h>
 #include <vlc_fs.h>
 #include <vlc_strings.h>
+#include <vlc_modules.h>
 
 #ifdef HAVE_SYS_STAT_H
 #   include <sys/stat.h>
@@ -1167,7 +1168,7 @@ static void InitPrograms( input_thread_t * p_input )
                  prgm = strtok_r( NULL, ",", &buf ) )
             {
                 vlc_value_t val = { .i_int = atoi( prgm ) };
-                TAB_APPEND( list.i_count, list.p_values, val );
+                INSERT_ELEM( list.p_values, list.i_count, list.i_count, val );
             }
 
             if( list.i_count > 0 )
@@ -3167,7 +3168,7 @@ static void SubtitleAdd( input_thread_t *p_input, char *psz_subtitle, bool b_for
         free( psz_path );
     }
 
-    char *url = make_URI( psz_subtitle );
+    char *url = make_URI( psz_subtitle, "file" );
 
     var_Change( p_input, "spu-es", VLC_VAR_CHOICESCOUNT, &count, NULL );