]> git.sesse.net Git - ffmpeg/blobdiff - libavcodec/rawenc.c
avcodec/hevc_parser: Check init_get_bits8() for failure
[ffmpeg] / libavcodec / rawenc.c
index a6b6617c5bab2c9e1430d29620e2fac09caa2b3e..75e726920a152e266e7033cc7bc3c405dc39e413 100644 (file)
@@ -54,7 +54,7 @@ static int raw_encode(AVCodecContext *avctx, AVPacket *pkt,
     if (ret < 0)
         return ret;
 
-    if ((ret = ff_alloc_packet(pkt, ret)) < 0)
+    if ((ret = ff_alloc_packet2(avctx, pkt, ret, ret)) < 0)
         return ret;
     if ((ret = avpicture_layout((const AVPicture *)frame, avctx->pix_fmt, avctx->width,
                                 avctx->height, pkt->data, pkt->size)) < 0)