summaryrefslogtreecommitdiff
path: root/libavcodec/bitstream.c
diff options
context:
space:
mode:
authorMichael Niedermayer <michael@niedermayer.cc>2017-01-05 11:56:00 +0100
committerMichael Niedermayer <michael@niedermayer.cc>2017-01-05 12:08:23 +0100
commit8f1d18a91be942ea646a3c074bee35c6046882af (patch)
tree1fa019530a77d15fa23dd3b32b538f152cbe530c /libavcodec/bitstream.c
parentf3adb6f74b8c39c0da8d828c962e61cd2692fc4c (diff)
downloadffmpeg-8f1d18a91be942ea646a3c074bee35c6046882af.tar.gz
avcodec/bitstream: assert that *_size in ff_init_vlc_sparse() is valid
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
Diffstat (limited to 'libavcodec/bitstream.c')
-rw-r--r--libavcodec/bitstream.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/libavcodec/bitstream.c b/libavcodec/bitstream.c
index 562ca1cb82..8deaa4abb8 100644
--- a/libavcodec/bitstream.c
+++ b/libavcodec/bitstream.c
@@ -99,9 +99,11 @@ void avpriv_copy_bits(PutBitContext *pb, const uint8_t *src, int length)
case 2: \
v = *(const uint16_t *)ptr; \
break; \
- default: \
+ case 4: \
v = *(const uint32_t *)ptr; \
break; \
+ default: \
+ av_assert1(0); \
} \
}