[FFmpeg-cvslog] avcodec/exr: fix clearing end of bitmap
Paul B Mahol
git at videolan.org
Tue Apr 12 22:56:01 CEST 2016
ffmpeg | branch: master | Paul B Mahol <onemda at gmail.com> | Tue Apr 12 21:39:32 2016 +0200| [392b0a25c236e7dc7e4976a5f1bed7485f801059] | committer: Paul B Mahol
avcodec/exr: fix clearing end of bitmap
Inspired by patch from Martin Vignali.
Signed-off-by: Paul B Mahol <onemda at gmail.com>
> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=392b0a25c236e7dc7e4976a5f1bed7485f801059
---
libavcodec/exr.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/libavcodec/exr.c b/libavcodec/exr.c
index 9dd2ee9..250d99f 100644
--- a/libavcodec/exr.c
+++ b/libavcodec/exr.c
@@ -768,7 +768,7 @@ static int piz_uncompress(EXRContext *s, const uint8_t *src, int ssize,
if (min_non_zero <= max_non_zero)
bytestream2_get_buffer(&gb, td->bitmap + min_non_zero,
max_non_zero - min_non_zero + 1);
- memset(td->bitmap + max_non_zero, 0, BITMAP_SIZE - max_non_zero);
+ memset(td->bitmap + max_non_zero + 1, 0, BITMAP_SIZE - max_non_zero - 1);
maxval = reverse_lut(td->bitmap, td->lut);
More information about the ffmpeg-cvslog
mailing list