diff options
author | Justin Ruggles <justin.ruggles@gmail.com> | 2011-09-21 14:16:24 -0400 |
---|---|---|
committer | Justin Ruggles <justin.ruggles@gmail.com> | 2011-10-25 11:22:01 -0400 |
commit | 35f9d8c20a26a7d383d3d36796e64a4b8987d743 (patch) | |
tree | fabb216c5d1748d42248d9d6a8b4d48a3b5c9504 | |
parent | 3d813e4c548c99368876f985a324eac689385311 (diff) | |
download | ffmpeg-35f9d8c20a26a7d383d3d36796e64a4b8987d743.tar.gz |
tta: check remaining bitstream size while reading unary value
-rw-r--r-- | libavcodec/tta.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/libavcodec/tta.c b/libavcodec/tta.c index 5a11436ca9..9330e2d549 100644 --- a/libavcodec/tta.c +++ b/libavcodec/tta.c @@ -182,7 +182,7 @@ static int tta_get_unary(GetBitContext *gb) int ret = 0; // count ones - while(get_bits1(gb)) + while (get_bits_left(gb) > 0 && get_bits1(gb)) ret++; return ret; } |