[FFmpeg-devel] [PATCH] snow: remove strange av_assert2

Andreas Cadhalpun andreas.cadhalpun at googlemail.com
Fri Jul 3 00:31:31 CEST 2015


It asserts that the frame linesize is larger than 37, but it can be
smaller and decoding such frames works. Thus it is unclear what this
assert is good for.

Signed-off-by: Andreas Cadhalpun <Andreas.Cadhalpun at googlemail.com>
---

This av_assert2 can be triggered with:
$ ffmpeg -f lavfi -i testsrc=s=32x32:d=0.1 -c snow snow.nut
$ ffmpeg -i test.snow -f null /dev/null

---
 libavcodec/snow.h | 2 --
 1 file changed, 2 deletions(-)

diff --git a/libavcodec/snow.h b/libavcodec/snow.h
index 95e07cd..3773028 100644
--- a/libavcodec/snow.h
+++ b/libavcodec/snow.h
@@ -347,8 +347,6 @@ static av_always_inline void add_yblock(SnowContext *s, int sliced, slice_buffer
 
     if(b_w<=0 || b_h<=0) return;
 
-    av_assert2(src_stride > 2*MB_SIZE + 5);
-
     if(!sliced && offset_dst)
         dst += src_x + src_y*dst_stride;
     dst8+= src_x + src_y*src_stride;
-- 
2.1.4


More information about the ffmpeg-devel mailing list