ra288: return error if input buffer is too small
authorJustin Ruggles <justin.ruggles@gmail.com>
Fri, 4 Nov 2011 00:41:17 +0000 (20:41 -0400)
committerJustin Ruggles <justin.ruggles@gmail.com>
Tue, 8 Nov 2011 17:36:56 +0000 (12:36 -0500)
libavcodec/ra288.c

index c58bc31..ddbda1d 100644 (file)
@@ -178,7 +178,7 @@ static int ra288_decode_frame(AVCodecContext * avctx, void *data,
         av_log(avctx, AV_LOG_ERROR,
                "Error! Input buffer is too small [%d<%d]\n",
                buf_size, avctx->block_align);
-        return 0;
+        return AVERROR_INVALIDDATA;
     }
 
     out_size = RA288_BLOCK_SIZE * RA288_BLOCKS_PER_FRAME *