]> git.sesse.net Git - vlc/commitdiff
avformat mux: use a variable
authorRafaël Carré <funman@videolan.org>
Fri, 21 Feb 2014 13:47:00 +0000 (14:47 +0100)
committerRafaël Carré <funman@videolan.org>
Fri, 21 Feb 2014 13:47:45 +0000 (14:47 +0100)
modules/demux/avformat/mux.c

index 0501e98760584ab4d2058f27599ea0fd35f9d9f4..fdcc8c7e19de00c50bb2b777094dfd0c45650129 100644 (file)
@@ -441,6 +441,7 @@ static int Control( sout_mux_t *p_mux, int i_query, va_list args )
 static int IOWrite( void *opaque, uint8_t *buf, int buf_size )
 {
     sout_mux_t *p_mux = opaque;
+    sout_mux_sys_t *p_sys = p_mux->p_sys;
     int i_ret;
 
 #ifdef AVFORMAT_DEBUG
@@ -450,13 +451,13 @@ static int IOWrite( void *opaque, uint8_t *buf, int buf_size )
     block_t *p_buf = block_Alloc( buf_size );
     if( buf_size > 0 ) memcpy( p_buf->p_buffer, buf, buf_size );
 
-    if( p_mux->p_sys->b_write_header )
+    if( p_sys->b_write_header )
         p_buf->i_flags |= BLOCK_FLAG_HEADER;
 
-    if( p_mux->p_sys->b_write_keyframe )
+    if( p_sys->b_write_keyframe )
     {
         p_buf->i_flags |= BLOCK_FLAG_TYPE_I;
-        p_mux->p_sys->b_write_keyframe = false;
+        p_sys->b_write_keyframe = false;
     }
 
     i_ret = sout_AccessOutWrite( p_mux->p_access, p_buf );