]> git.sesse.net Git - vlc/blobdiff - modules/demux/ts.c
httplive: Adjust conditions for playlist reloading
[vlc] / modules / demux / ts.c
index b958408c2e4f0765685fa127e2c0bf90f2ab87af..f6c6fefd1db4b287b20dd6437538029c84b39220 100644 (file)
@@ -1201,13 +1201,13 @@ static int Control( demux_t *p_demux, int i_query, va_list args )
     }
 
     case DEMUX_SET_TITLE:
-        return stream_Control( p_demux->s, STREAM_SET_TITLE, args );
+        return stream_vaControl( p_demux->s, STREAM_SET_TITLE, args );
 
     case DEMUX_SET_SEEKPOINT:
-        return stream_Control( p_demux->s, STREAM_SET_SEEKPOINT, args );
+        return stream_vaControl( p_demux->s, STREAM_SET_SEEKPOINT, args );
 
     case DEMUX_GET_META:
-        return stream_Control( p_demux->s, STREAM_GET_META, args );
+        return stream_vaControl( p_demux->s, STREAM_GET_META, args );
 
     case DEMUX_CAN_RECORD:
         pb_bool = (bool*)va_arg( args, bool * );
@@ -1223,7 +1223,7 @@ static int Control( demux_t *p_demux, int i_query, va_list args )
         return VLC_SUCCESS;
 
     case DEMUX_GET_SIGNAL:
-        return stream_Control( p_demux->s, STREAM_GET_SIGNAL, args );
+        return stream_vaControl( p_demux->s, STREAM_GET_SIGNAL, args );
 
     default:
         return VLC_EGENERIC;
@@ -1240,6 +1240,7 @@ static int UserPmt( demux_t *p_demux, const char *psz_fmt )
     char *psz = psz_dup;
     int  i_pid;
     int  i_number;
+    ts_prg_psi_t *prg = NULL;
 
     if( !psz_dup )
         return VLC_ENOMEM;
@@ -1256,7 +1257,6 @@ static int UserPmt( demux_t *p_demux, const char *psz_fmt )
 
     /* */
     ts_pid_t *pmt = &p_sys->pid[i_pid];
-    ts_prg_psi_t *prg;
 
     msg_Dbg( p_demux, "user pmt specified (pid=%d,number=%d)", i_pid, i_number );
     PIDInit( pmt, true, NULL );
@@ -2021,7 +2021,7 @@ static int Seek( demux_t *p_demux, double f_percent )
     mtime_t i_target_pcr = (p_sys->i_last_pcr - p_sys->i_first_pcr) * f_percent + p_sys->i_first_pcr;
 
     int64_t i_head_pos = 0;
-    int64_t i_tail_pos = stream_Size( p_demux->s );
+    int64_t i_tail_pos;
     {
         mtime_t i_adjust = 0;
         int i;
@@ -3527,7 +3527,8 @@ static void PMTSetupEsTeletext( demux_t *p_demux, ts_pid_t *pid,
 
             /* */
             const ts_teletext_page_t *p = &p_page[i];
-            p_es->fmt.i_priority = (p->i_type == 0x02 || p->i_type == 0x05) ? 0 : -1;
+            p_es->fmt.i_priority = (p->i_type == 0x02 || p->i_type == 0x05) ?
+                      ES_PRIORITY_SELECTABLE_MIN : ES_PRIORITY_NOT_DEFAULTABLE;
             p_es->fmt.psz_language = strndup( p->p_iso639, 3 );
             p_es->fmt.psz_description = strdup(vlc_gettext(ppsz_teletext_type[p->i_type]));
             p_es->fmt.subs.teletext.i_magazine = p->i_magazine;
@@ -3922,7 +3923,7 @@ static void PMTParseEsIso639( demux_t *p_demux, ts_pid_t *pid,
     int type = p_decoded->code[0].i_audio_type;
     pid->es->fmt.psz_description = GetAudioTypeDesc(p_demux, type);
     if (type == 0)
-        pid->es->fmt.i_priority = 1; // prioritize normal audio tracks
+        pid->es->fmt.i_priority = ES_PRIORITY_SELECTABLE_MIN + 1; // prioritize normal audio tracks
 
     pid->es->fmt.i_extra_languages = p_decoded->i_code_count-1;
     if( pid->es->fmt.i_extra_languages > 0 )
@@ -4045,7 +4046,7 @@ static void PMTCallBack( void *data, dvbpsi_pmt_t *p_pmt )
             else
             {
                 msg_Dbg( p_demux, " * descriptor : registration %4.4s", p_dr->p_data );
-                if( !memcmp( p_dr->p_data, "HDMV", 4 ) )
+                if( !memcmp( p_dr->p_data, "HDMV", 4 ) || !memcmp( p_dr->p_data, "HDPR", 4 ) )
                     b_hdmv = true; /* Blu-Ray */
             }
             break;