Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/FFmpeg/FFmpeg.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichael Niedermayer <michaelni@gmx.at>2011-05-01 04:32:41 +0400
committerMichael Niedermayer <michaelni@gmx.at>2011-05-01 04:38:30 +0400
commitc059d7aa57391f2216808dbf2afdcb9e0a835ab5 (patch)
tree303b19c419257dbf00643a245c4fd5ee2bd84726 /libavcodec/h264_refs.c
parent0ae4aba649dffd6de4594715be06e1ec39d374d5 (diff)
H264: Fix intra only decoding.
This possibly fixes issue2679 Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat (limited to 'libavcodec/h264_refs.c')
-rw-r--r--libavcodec/h264_refs.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/libavcodec/h264_refs.c b/libavcodec/h264_refs.c
index c13059ae69..43c39da3c9 100644
--- a/libavcodec/h264_refs.c
+++ b/libavcodec/h264_refs.c
@@ -622,7 +622,7 @@ int ff_h264_execute_ref_pic_marking(H264Context *h, MMCO *mmco, int mmco_count){
}
}
- if (h->long_ref_count + h->short_ref_count > h->sps.ref_frame_count){
+ if (h->long_ref_count + h->short_ref_count > FFMAX(h->sps.ref_frame_count, 1)){
/* We have too many reference frames, probably due to corrupted
* stream. Need to discard one frame. Prevents overrun of the