]> git.sesse.net Git - ffmpeg/blobdiff - libavformat/rtpdec_h263_rfc2190.c
avconv: Check rc_override memory allocation
[ffmpeg] / libavformat / rtpdec_h263_rfc2190.c
index 4b6e9967701631e83d399a40242b1a6d9145639b..d507ef7ef32fcdc9e2c87623ba85902cbd8801a0 100644 (file)
@@ -27,6 +27,7 @@
 
 #include "avformat.h"
 #include "rtpdec_formats.h"
+#include "libavutil/attributes.h"
 #include "libavutil/intreadwrite.h"
 #include "libavcodec/get_bits.h"
 
@@ -55,7 +56,7 @@ static void h263_free_context(PayloadContext *data)
     av_free(data);
 }
 
-static int h263_init(AVFormatContext *ctx, int st_index, PayloadContext *data)
+static av_cold int h263_init(AVFormatContext *ctx, int st_index, PayloadContext *data)
 {
     if (st_index < 0)
         return 0;
@@ -82,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) {