From 2bd303f95c0d689be777625332be20ed91bfb0a8 Mon Sep 17 00:00:00 2001 From: Michael Niedermayer Date: Thu, 22 Mar 2012 15:00:50 +0100 Subject: [PATCH] zmbvenc: switch to ff_alloc_packet2(). Signed-off-by: Michael Niedermayer --- libavcodec/zmbvenc.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/libavcodec/zmbvenc.c b/libavcodec/zmbvenc.c index a7fdc280a5..3453d69a82 100644 --- a/libavcodec/zmbvenc.c +++ b/libavcodec/zmbvenc.c @@ -228,8 +228,7 @@ static int encode_frame(AVCodecContext *avctx, AVPacket *pkt, } pkt_size = c->zstream.total_out + 1 + 6*keyframe; - if ((ret = ff_alloc_packet(pkt, pkt_size)) < 0) { - av_log(avctx, AV_LOG_ERROR, "Error getting packet of size %d.\n", pkt_size); + if ((ret = ff_alloc_packet2(avctx, pkt, pkt_size)) < 0) { return ret; } buf = pkt->data;