Compile fix to check for ffmpeg version.
authorJean-Paul Saman <jpsaman@videolan.org>
Fri, 23 Nov 2007 14:12:31 +0000 (14:12 +0000)
committerJean-Paul Saman <jpsaman@videolan.org>
Fri, 23 Nov 2007 14:12:31 +0000 (14:12 +0000)
modules/codec/ffmpeg/mux.c

index 0e194fe..fd3bae2 100644 (file)
@@ -148,7 +148,11 @@ int E_(OpenMux)( vlc_object_t *p_this )
         return VLC_EGENERIC;
     }
 
+#if LIBAVFORMAT_VERSION_INT >= ((52<<16)+(0<<8)+0)
     p_sys->oc->pb = &p_sys->io;
+#else
+    p_sys->oc->pb = p_sys->io;
+#endif
     p_sys->oc->nb_streams = 0;
 
     p_sys->b_write_header = VLC_TRUE;
@@ -394,7 +398,11 @@ static int Mux( sout_mux_t *p_mux )
             return VLC_EGENERIC;
         }
 
+#if LIBAVFORMAT_VERSION_INT >= ((52<<16)+(0<<8)+0)
         put_flush_packet( p_sys->oc->pb );
+#else
+        put_flush_packet( &p_sys->oc->pb );
+#endif
         p_sys->b_write_header = VLC_FALSE;
     }