diff mbox

[FFmpeg-devel,2/4] avcodec/interplayvideo: Avoid ff_get_buffer() during init

Message ID 20190711214940.13431-2-michael@niedermayer.cc
State Accepted
Commit a3adc3b6a0a882bbe918dc2f6c11b734e1d76037
Headers show

Commit Message

Michael Niedermayer July 11, 2019, 9:49 p.m. UTC
This is unneeded for interplay video

Fixes: memleak
Fixes: 15562/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_INTERPLAY_VIDEO_fuzzer-5162268645392384

Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
---
 libavcodec/interplayvideo.c | 8 --------
 1 file changed, 8 deletions(-)

Comments

Michael Niedermayer Aug. 3, 2019, 3:23 p.m. UTC | #1
On Thu, Jul 11, 2019 at 11:49:38PM +0200, Michael Niedermayer wrote:
> This is unneeded for interplay video
> 
> Fixes: memleak
> Fixes: 15562/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_INTERPLAY_VIDEO_fuzzer-5162268645392384
> 
> Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
> Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
> ---
>  libavcodec/interplayvideo.c | 8 --------
>  1 file changed, 8 deletions(-)

will apply

[...]
diff mbox

Patch

diff --git a/libavcodec/interplayvideo.c b/libavcodec/interplayvideo.c
index 4313fdf7ac..c26ffbaee7 100644
--- a/libavcodec/interplayvideo.c
+++ b/libavcodec/interplayvideo.c
@@ -1181,14 +1181,6 @@  static av_cold int ipvideo_decode_init(AVCodecContext *avctx)
     s->cur_decode_frame->format  = avctx->pix_fmt;
     s->prev_decode_frame->format = avctx->pix_fmt;
 
-    ret = ff_get_buffer(avctx, s->cur_decode_frame, 0);
-    if (ret < 0)
-        goto error;
-
-    ret = ff_get_buffer(avctx, s->prev_decode_frame, 0);
-    if (ret < 0)
-        goto error;
-
     return 0;
 error:
     av_frame_free(&s->last_frame);