[FFmpeg-cvslog] 4xm: drop pointless assert
Luca Barbato
git at videolan.org
Tue Aug 27 15:59:04 CEST 2013
ffmpeg | branch: release/1.1 | Luca Barbato <lu_zero at gentoo.org> | Thu Jun 6 14:21:19 2013 +0200| [f82e9deec2c2657d73731ab16c49efba5559670d] | committer: Luca Barbato
4xm: drop pointless assert
Make sure the value of wlog2 is always between 0 and 3.
(cherry picked from commit 1f0c6075604c271d5627480f1243d22795f9a315)
Signed-off-by: Luca Barbato <lu_zero at gentoo.org>
> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=f82e9deec2c2657d73731ab16c49efba5559670d
---
libavcodec/4xm.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/libavcodec/4xm.c b/libavcodec/4xm.c
index 696d2cf..4973b41 100644
--- a/libavcodec/4xm.c
+++ b/libavcodec/4xm.c
@@ -329,7 +329,7 @@ static inline void mcdc(uint16_t *dst, uint16_t *src, int log2w,
}
break;
default:
- assert(0);
+ break;
}
}
@@ -345,7 +345,7 @@ static int decode_p_block(FourXContext *f, uint16_t *dst, uint16_t *src,
uint16_t *end = start + stride * (f->avctx->height - h + 1) - (1 << log2w);
int ret;
- if (code < 0 || code > 6)
+ if (code < 0 || code > 6 || log2w < 0)
return AVERROR_INVALIDDATA;
if (code == 0) {
More information about the ffmpeg-cvslog
mailing list