Merge commit 'e30b068ef79f604ff439418da07f7e2efd01d4ea'
[ffmpeg.git] / libavcodec / wmaprodec.c
index a71a67e12d22bf6705cdd07cb8d1d98492993182..580b7b454b7cf8efdcb942e5c52d2a87acaba57f 100644 (file)
@@ -1469,6 +1469,8 @@ static void save_bits(WMAProDecodeCtx *s, GetBitContext* gb, int len,
         return;
     }
 
+    av_assert0(len <= put_bits_left(&s->pb));
+
     s->num_saved_bits += len;
     if (!append) {
         avpriv_copy_bits(&s->pb, gb->buffer + (get_bits_count(gb) >> 3),