summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--libavcodec/adpcm.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/libavcodec/adpcm.c b/libavcodec/adpcm.c
index c3ae66effc..bced66f198 100644
--- a/libavcodec/adpcm.c
+++ b/libavcodec/adpcm.c
@@ -444,6 +444,9 @@ static int adpcm_decode_frame(AVCodecContext *avctx,
int decode_top_nibble_next = 0;
int diff_channel;
+ if (!buf_size)
+ return 0;
+
samples = data;
src = buf;