[vlc-commits] avformat: prefer avformat_new_stream() over av_new_stream() ( cherry picked from commit 5dbdccf2fd7829a8a0fb3ccae65ed17f71c7078a)

Rafaël Carré git at videolan.org
Sun Mar 4 22:42:03 CET 2012


vlc/vlc-2.0 | branch: master | Rafaël Carré <funman at videolan.org> | Sat Mar  3 00:03:09 2012 +0900| [07b4be40246575d96f4684772b898bc3f3ba5208] | committer: Rafaël Carré

avformat: prefer avformat_new_stream() over av_new_stream() (cherry picked from commit 5dbdccf2fd7829a8a0fb3ccae65ed17f71c7078a)

Signed-off-by: KO Myung-Hun <komh at chollian.net>
Signed-off-by: Rafaël Carré <funman at videolan.org>

> http://git.videolan.org/gitweb.cgi/vlc/vlc-2.0.git/?a=commit;h=07b4be40246575d96f4684772b898bc3f3ba5208
---

 modules/demux/avformat/mux.c |    4 ++++
 1 files changed, 4 insertions(+), 0 deletions(-)

diff --git a/modules/demux/avformat/mux.c b/modules/demux/avformat/mux.c
index b30392c..8dccbbe 100644
--- a/modules/demux/avformat/mux.c
+++ b/modules/demux/avformat/mux.c
@@ -211,7 +211,11 @@ static int AddStream( sout_mux_t *p_mux, sout_input_t *p_input )
         return VLC_EGENERIC;
     }
 
+#if (LIBAVFORMAT_VERSION_INT >= ((53<<16)+(10<<8)+0))
+    stream = avformat_new_stream( p_sys->oc, NULL);
+#else
     stream = av_new_stream( p_sys->oc, p_sys->oc->nb_streams);
+#endif
     if( !stream )
     {
         free( p_input->p_sys );



More information about the vlc-commits mailing list