aboutsummaryrefslogtreecommitdiffstats
path: root/libavcodec/pcxenc.c
diff options
context:
space:
mode:
authorMichael Niedermayer <michaelni@gmx.at>2012-03-22 15:00:48 +0100
committerMichael Niedermayer <michaelni@gmx.at>2012-03-22 19:03:21 +0100
commitd2c4b3754dd793b8be22314e3e3411511616cad7 (patch)
tree30f581e6f498f2df8caa414da9ef983932adb7d8 /libavcodec/pcxenc.c
parent11e8f3e7a20db6f584f523a85e730ca60550ba3d (diff)
downloadffmpeg-d2c4b3754dd793b8be22314e3e3411511616cad7.tar.gz
pcxenc: switch to ff_alloc_packet2().
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat (limited to 'libavcodec/pcxenc.c')
-rw-r--r--libavcodec/pcxenc.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/libavcodec/pcxenc.c b/libavcodec/pcxenc.c
index 65b3935476..27af2aa9dd 100644
--- a/libavcodec/pcxenc.c
+++ b/libavcodec/pcxenc.c
@@ -153,8 +153,7 @@ static int pcx_encode_frame(AVCodecContext *avctx, AVPacket *pkt,
line_bytes = (line_bytes + 1) & ~1;
max_pkt_size = 128 + avctx->height * 2 * line_bytes * nplanes + (pal ? 256*3 + 1 : 0);
- if ((ret = ff_alloc_packet(pkt, max_pkt_size)) < 0) {
- av_log(avctx, AV_LOG_ERROR, "Error getting output packet of size %d.\n", max_pkt_size);
+ if ((ret = ff_alloc_packet2(avctx, pkt, max_pkt_size)) < 0) {
return ret;
}
buf = pkt->data;