]> git.sesse.net Git - vlc/commitdiff
mux_asf: use VLC_TS_INVALID (refs #3135)
authorRafaël Carré <rafael.carre@gmail.com>
Tue, 8 Dec 2009 10:26:28 +0000 (11:26 +0100)
committerRafaël Carré <rafael.carre@gmail.com>
Tue, 8 Dec 2009 10:26:28 +0000 (11:26 +0100)
modules/mux/asf.c

index 804e61039103cbd61fee3e0a787dbc655c769452..a50e3cfb7236f7f03bcff0a7df36104dea05e3f2 100644 (file)
@@ -213,8 +213,8 @@ static int Open( vlc_object_t *p_this )
     p_sys->pk = NULL;
     p_sys->i_pk_used    = 0;
     p_sys->i_pk_frame   = 0;
-    p_sys->i_dts_first  = -1;
-    p_sys->i_dts_last   = 0;
+    p_sys->i_dts_first  =
+    p_sys->i_dts_last   = VLC_TS_INVALID;
     p_sys->i_preroll_time = 2000;
     p_sys->i_bitrate    = 0;
     p_sys->i_bitrate_override = 0;
@@ -706,7 +706,7 @@ static int Mux( sout_mux_t *p_mux )
             return VLC_SUCCESS;
         }
 
-        if( p_sys->i_dts_first < 0 )
+        if( p_sys->i_dts_first < VLC_TS_INVALID )
         {
             p_sys->i_dts_first = i_dts;
         }
@@ -929,7 +929,7 @@ static block_t *asf_header_create( sout_mux_t *p_mux, bool b_broadcast )
 
     msg_Dbg( p_mux, "Asf muxer creating header" );
 
-    if( p_sys->i_dts_first > 0 )
+    if( p_sys->i_dts_first > VLC_TS_INVALID )
     {
         i_duration = p_sys->i_dts_last - p_sys->i_dts_first;
         if( i_duration < 0 ) i_duration = 0;