rtpdec_h263_rfc2190: Clear the stored bits if discarding buffered data
authorMartin Storsjö <martin@martin.st>
Wed, 17 Dec 2014 11:50:06 +0000 (13:50 +0200)
committerMichael Niedermayer <michaelni@gmx.at>
Thu, 12 Feb 2015 16:10:35 +0000 (17:10 +0100)
If we throw away the buffered incomplete frame, make sure to also
throw away the buffered bits of an incomplete byte at the same
time.

(cherry picked from commit df07c07b3de0a5e8890078944de1eb5cb8372ef8)
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
libavformat/rtpdec_h263_rfc2190.c

index a227901..8a36e53 100644 (file)
@@ -83,6 +83,7 @@ static int h263_handle_packet(AVFormatContext *ctx, PayloadContext *data,
         avio_close_dyn_buf(data->buf, &p);
         av_free(p);
         data->buf = NULL;
+        data->endbyte_bits = 0;
     }
 
     if (len < 4) {