[FFmpeg-cvslog] sgienc: switch to ff_alloc_packet2().
Michael Niedermayer
git at videolan.org
Thu Mar 22 19:10:35 CET 2012
ffmpeg | branch: master | Michael Niedermayer <michaelni at gmx.at> | Thu Mar 22 15:00:49 2012 +0100| [b911d7dc604afbb21f0a1fd74e90522b3dad61fb] | committer: Michael Niedermayer
sgienc: switch to ff_alloc_packet2().
Signed-off-by: Michael Niedermayer <michaelni at gmx.at>
> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=b911d7dc604afbb21f0a1fd74e90522b3dad61fb
---
libavcodec/sgienc.c | 3 +--
1 files changed, 1 insertions(+), 2 deletions(-)
diff --git a/libavcodec/sgienc.c b/libavcodec/sgienc.c
index 42202a4..0f317c7 100644
--- a/libavcodec/sgienc.c
+++ b/libavcodec/sgienc.c
@@ -113,8 +113,7 @@ static int encode_frame(AVCodecContext *avctx, AVPacket *pkt,
else // assume ff_rl_encode() produces at most 2x size of input
length += tablesize * 2 + depth * height * (2 * width + 1);
- if ((ret = ff_alloc_packet(pkt, bytes_per_channel * length)) < 0) {
- av_log(avctx, AV_LOG_ERROR, "Error getting output packet of size %d.\n", length);
+ if ((ret = ff_alloc_packet2(avctx, pkt, bytes_per_channel * length)) < 0) {
return ret;
}
buf = pkt->data;
More information about the ffmpeg-cvslog
mailing list