aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJustin Ruggles <justin.ruggles@gmail.com>2011-10-28 10:09:45 -0400
committerJustin Ruggles <justin.ruggles@gmail.com>2011-11-02 14:41:16 -0400
commita2e255783e2701b1bd4b59c1c309580f375fb138 (patch)
tree0cd81c2cb624da3b92a57593cc074207d8763a28
parentfc43fc9faa6edc3c8df76cfa51510a98958563e6 (diff)
downloadffmpeg-a2e255783e2701b1bd4b59c1c309580f375fb138.tar.gz
gsmdec: do not needlessly set *data_size to 0
-rw-r--r--libavcodec/gsmdec.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/libavcodec/gsmdec.c b/libavcodec/gsmdec.c
index 77c22e5d79..f084b14553 100644
--- a/libavcodec/gsmdec.c
+++ b/libavcodec/gsmdec.c
@@ -65,7 +65,7 @@ static int gsm_decode_frame(AVCodecContext *avctx, void *data,
av_log(avctx, AV_LOG_ERROR, "Output buffer is too small\n");
return AVERROR(EINVAL);
}
- *data_size = 0;
+
if(buf_size < avctx->block_align)
return AVERROR_INVALIDDATA;