summaryrefslogtreecommitdiff
path: root/libavcodec/tiff.c
diff options
context:
space:
mode:
authorStefano Sabatini <stefano.sabatini-lala@poste.it>2011-05-09 22:11:57 +0200
committerAnton Khirnov <anton@khirnov.net>2011-06-05 12:49:14 +0200
commita43458d7eb32c2cc560c58c78949f152a8e95e3d (patch)
tree4497b0fc8aca3d572a399f8a3f29d3d9e97dc05d /libavcodec/tiff.c
parent5a4a71257c0d0b1f4a5b4f0ebd4d96515feea23a (diff)
tiff: fix linesize for mono-white/black formats.
Fix decoding of file Test_1bpp.tif Signed-off-by: Anton Khirnov <anton@khirnov.net>
Diffstat (limited to 'libavcodec/tiff.c')
-rw-r--r--libavcodec/tiff.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/libavcodec/tiff.c b/libavcodec/tiff.c
index bea353275f..eaaeb84425 100644
--- a/libavcodec/tiff.c
+++ b/libavcodec/tiff.c
@@ -105,7 +105,7 @@ static int tiff_uncompress(uint8_t *dst, unsigned long *len, const uint8_t *src,
static int tiff_unpack_strip(TiffContext *s, uint8_t* dst, int stride, const uint8_t *src, int size, int lines){
int c, line, pixels, code;
const uint8_t *ssrc = src;
- int width = s->width * s->bpp >> 3;
+ int width = ((s->width * s->bpp) + 7) >> 3;
#if CONFIG_ZLIB
uint8_t *zbuf; unsigned long outlen;