[vlc-devel] commit: Fix subtitle commit for old versions of avcodec. ( Jean-Baptiste Kempf )

git version control git at videolan.org
Fri Aug 28 09:39:08 CEST 2009


vlc | branch: master | Jean-Baptiste Kempf <jb at videolan.org> | Fri Aug 28 00:46:54 2009 +0200| [5082bfea71cc83c7c451c41de3f6a6f615552adf] | committer: Jean-Baptiste Kempf 

Fix subtitle commit for old versions of avcodec.

> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=5082bfea71cc83c7c451c41de3f6a6f615552adf
---

 modules/codec/avcodec/subtitle.c |    4 ++++
 1 files changed, 4 insertions(+), 0 deletions(-)

diff --git a/modules/codec/avcodec/subtitle.c b/modules/codec/avcodec/subtitle.c
index f3f8a86..b6110f1 100644
--- a/modules/codec/avcodec/subtitle.c
+++ b/modules/codec/avcodec/subtitle.c
@@ -100,6 +100,7 @@ int InitSubtitleDec(decoder_t *dec, AVCodecContext *context,
  */
 subpicture_t *DecodeSubtitle(decoder_t *dec, block_t **block_ptr)
 {
+#if LIBAVCODEC_VERSION_INT >= AV_VERSION_INT( 52, 25, 0 )
     decoder_sys_t *sys = dec->p_sys;
 
     if (!block_ptr || !*block_ptr)
@@ -163,6 +164,9 @@ subpicture_t *DecodeSubtitle(decoder_t *dec, block_t **block_ptr)
     if (!spu)
         block_Release(block);
     return spu;
+#else
+    return NULL;
+#endif
 }
 
 /**




More information about the vlc-devel mailing list