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>2013-10-20 16:09:55 +0400
committerMichael Niedermayer <michaelni@gmx.at>2013-10-20 16:46:23 +0400
commitf198efb179cb33d96b262925f89ba8fa389ac5cd (patch)
tree25869bbef8a43e64021e85b7aa3118157e075185 /libavcodec/vp9.c
parentc9a22d69afc74f31462c321a64f493587e9f28cd (diff)
avcodec/vp9: Add asserts to help source code analyzers
See CID1108596 and CID1108595 Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat (limited to 'libavcodec/vp9.c')
-rw-r--r--libavcodec/vp9.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/libavcodec/vp9.c b/libavcodec/vp9.c
index 012d7aad22..1d0646023d 100644
--- a/libavcodec/vp9.c
+++ b/libavcodec/vp9.c
@@ -1169,6 +1169,7 @@ static void decode_mode(AVCodecContext *ctx)
for (y = 0; y < h4; y++)
for (x = 0; x < w4; x++)
pred = FFMIN(pred, s->segmentation_map[(y + row) * 8 * s->sb_cols + x + col]);
+ av_assert1(pred < 8);
b->seg_id = pred;
memset(&s->above_segpred_ctx[col], 1, w4);
@@ -3312,6 +3313,7 @@ static int vp9_decode_frame(AVCodecContext *ctx, void *out_pic,
for (i = 0; i < 10; i++)
if (!s->fb[i]->data[0])
break;
+ av_assert0(i < 10);
s->f = s->fb[i];
if ((res = ff_get_buffer(ctx, s->f,
s->refreshrefmask ? AV_GET_BUFFER_FLAG_REF : 0)) < 0)