---
 libavcodec/libopencore-amr.c |    8 +++-----
 1 files changed, 3 insertions(+), 5 deletions(-)

diff --git a/libavcodec/libopencore-amr.c b/libavcodec/libopencore-amr.c
index c04cf99..8cee785 100644
--- a/libavcodec/libopencore-amr.c
+++ b/libavcodec/libopencore-amr.c
@@ -110,7 +110,6 @@ static int amr_nb_decode_frame(AVCodecContext *avctx, void 
*data,
     const uint8_t *buf = avpkt->data;
     int buf_size       = avpkt->size;
     AMRContext *s = avctx->priv_data;
-    const uint8_t *amrData = buf;
     static const uint8_t block_size[16] = { 12, 13, 15, 17, 19, 20, 26, 31, 5, 
0, 0, 0, 0, 0, 0, 0 };
     enum Mode dec_mode;
     int packet_size;
@@ -125,7 +124,7 @@ static int amr_nb_decode_frame(AVCodecContext *avctx, void 
*data,
     }
 
     /* call decoder */
-    Decoder_Interface_Decode(s->decState, amrData, data, 0);
+    Decoder_Interface_Decode(s->decState, buf, data, 0);
     *data_size = 160 * 2;
 
     return packet_size;
@@ -248,7 +247,6 @@ static int amr_wb_decode_frame(AVCodecContext *avctx, void 
*data,
     const uint8_t *buf = avpkt->data;
     int buf_size       = avpkt->size;
     AMRWBContext *s = avctx->priv_data;
-    const uint8_t *amrData = buf;
     int mode;
     int packet_size;
     static const uint8_t block_size[16] = {18, 24, 33, 37, 41, 47, 51, 59, 61, 
6, 6, 0, 0, 0, 1, 1};
@@ -257,7 +255,7 @@ static int amr_wb_decode_frame(AVCodecContext *avctx, void 
*data,
         /* nothing to do */
         return 0;
 
-    mode = (amrData[0] >> 3) & 0x000F;
+    mode = (buf[0] >> 3) & 0x000F;
     packet_size = block_size[mode];
 
     if (packet_size > buf_size) {
@@ -266,7 +264,7 @@ static int amr_wb_decode_frame(AVCodecContext *avctx, void 
*data,
         return AVERROR_INVALIDDATA;
     }
 
-    D_IF_decode(s->state, amrData, data, _good_frame);
+    D_IF_decode(s->state, buf, data, _good_frame);
     *data_size = 320 * 2;
     return packet_size;
 }
-- 
1.7.3.1

_______________________________________________
libav-devel mailing list
libav-devel@libav.org
https://lists.libav.org/mailman/listinfo/libav-devel

Reply via email to