summaryrefslogtreecommitdiff
path: root/libavcodec/bink.c
diff options
context:
space:
mode:
authorBastien Bouclet <bgkweb@gmail.com>2012-03-06 20:16:20 +0100
committerCarl Eugen Hoyos <cehoyos@ag.or.at>2012-03-06 20:20:41 +0100
commitb521f113493fb79fbaf26da669008ec7cdae7fbb (patch)
tree726159ed49a2fe4633379b6e7dba2995b5be4174 /libavcodec/bink.c
parent0f13cc732b3752828890b8dff507615cfd454336 (diff)
Fix bink decoder for files with 24px width.
Fixes ticket #962.
Diffstat (limited to 'libavcodec/bink.c')
-rw-r--r--libavcodec/bink.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/libavcodec/bink.c b/libavcodec/bink.c
index c501688ae8..7df5871030 100644
--- a/libavcodec/bink.c
+++ b/libavcodec/bink.c
@@ -148,7 +148,7 @@ static void init_lengths(BinkContext *c, int width, int bw)
{
c->bundle[BINK_SRC_BLOCK_TYPES].len = av_log2((width >> 3) + 511) + 1;
- c->bundle[BINK_SRC_SUB_BLOCK_TYPES].len = av_log2((width >> 4) + 511) + 1;
+ c->bundle[BINK_SRC_SUB_BLOCK_TYPES].len = av_log2(((width + 7) >> 4) + 511) + 1;
c->bundle[BINK_SRC_COLORS].len = av_log2(bw*64 + 511) + 1;