diff options
Diffstat (limited to 'libavcodec/libilbc.c')
-rw-r--r-- | libavcodec/libilbc.c | 16 |
1 files changed, 6 insertions, 10 deletions
diff --git a/libavcodec/libilbc.c b/libavcodec/libilbc.c index 80b69a562c..c4c054fa5d 100644 --- a/libavcodec/libilbc.c +++ b/libavcodec/libilbc.c @@ -2,20 +2,20 @@ * iLBC decoder/encoder stub * Copyright (c) 2012 Martin Storsjo * - * This file is part of Libav. + * This file is part of FFmpeg. * - * Libav is free software; you can redistribute it and/or + * FFmpeg is free software; you can redistribute it and/or * modify it under the terms of the GNU Lesser General Public * License as published by the Free Software Foundation; either * version 2.1 of the License, or (at your option) any later version. * - * Libav is distributed in the hope that it will be useful, + * FFmpeg is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with Libav; if not, write to the Free Software + * License along with FFmpeg; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA */ @@ -93,10 +93,8 @@ static int ilbc_decode_frame(AVCodecContext *avctx, void *data, } frame->nb_samples = s->decoder.blockl; - if ((ret = ff_get_buffer(avctx, frame, 0)) < 0) { - av_log(avctx, AV_LOG_ERROR, "get_buffer() failed\n"); + if ((ret = ff_get_buffer(avctx, frame, 0)) < 0) return ret; - } WebRtcIlbcfix_DecodeImpl((int16_t *) frame->data[0], (const uint16_t *) buf, &s->decoder, 1); @@ -168,10 +166,8 @@ static int ilbc_encode_frame(AVCodecContext *avctx, AVPacket *avpkt, ILBCEncContext *s = avctx->priv_data; int ret; - if ((ret = ff_alloc_packet(avpkt, 50))) { - av_log(avctx, AV_LOG_ERROR, "Error getting output packet\n"); + if ((ret = ff_alloc_packet2(avctx, avpkt, 50, 0)) < 0) return ret; - } WebRtcIlbcfix_EncodeImpl((uint16_t *) avpkt->data, (const int16_t *) frame->data[0], &s->encoder); |