[SCM] libav/wheezy-security: h264: reset next_output_pic earlier in start_frame()
siretart at users.alioth.debian.org
siretart at users.alioth.debian.org
Sun Jun 1 21:36:13 UTC 2014
The following commit has been merged in the wheezy-security branch:
commit 079758e49a4d6b3e7cf2e22bed71d34c46712242
Author: Anton Khirnov <anton at khirnov.net>
Date: Wed Apr 23 22:26:40 2014 +0200
h264: reset next_output_pic earlier in start_frame()
In case start_frame() fails, this potentially invalid frame can still be
output to the caller.
Bug-Id: 672
Bug-Id: debian/741240
Bug-Id: ubuntu/1288206
diff --git a/libavcodec/h264.c b/libavcodec/h264.c
index bca9bda..737fc0c 100644
--- a/libavcodec/h264.c
+++ b/libavcodec/h264.c
@@ -1281,6 +1281,8 @@ int ff_h264_frame_start(H264Context *h){
int i;
const int pixel_shift = h->pixel_shift;
+ h->next_output_pic = NULL;
+
if(MPV_frame_start(s, s->avctx) < 0)
return -1;
ff_er_frame_start(s);
@@ -1329,8 +1331,6 @@ int ff_h264_frame_start(H264Context *h){
s->current_picture_ptr->field_poc[0]=
s->current_picture_ptr->field_poc[1]= INT_MAX;
- h->next_output_pic = NULL;
-
assert(s->current_picture_ptr->long_ref==0);
return 0;
--
Libav/FFmpeg packaging
More information about the pkg-multimedia-commits
mailing list