Module: libav
Branch: release/0.6
Commit: 35f1888585e0ffa2f1334cf92fc0a16fb4a113a6

Author:    Laurent Aimar <[email protected]>
Committer: Reinhard Tartler <[email protected]>
Date:      Sat Sep 17 23:43:58 2011 +0200

rv34: Avoid NULL dereference on corrupted bitstream

rv34_decode_slice() can return without allocating any pictures.

Signed-off-by: Martin Storsjö <[email protected]>
(cherry picked from commit d0f6ab0298f2309c6104626787ed73416298b019)

Signed-off-by: Anton Khirnov <[email protected]>
Signed-off-by: Reinhard Tartler <[email protected]>

---

 libavcodec/rv34.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/libavcodec/rv34.c b/libavcodec/rv34.c
index 88652f9..a1dc799 100644
--- a/libavcodec/rv34.c
+++ b/libavcodec/rv34.c
@@ -1494,7 +1494,7 @@ int ff_rv34_decode_frame(AVCodecContext *avctx,
             break;
     }
 
-    if(last){
+    if(last && s->current_picture_ptr){
         if(r->loop_filter)
             r->loop_filter(r, s->mb_height - 1);
         ff_er_frame_end(s);

_______________________________________________
libav-commits mailing list
[email protected]
https://lists.libav.org/mailman/listinfo/libav-commits

Reply via email to