History

avfilter/src_movie: Fix leak of packet upon error

If allocating the AVFrame to contain a decoded frame fails, the AVPacket containing the data intended to be decoded leaks. This commit fixes this.

Andreas Rheinhardt committed 6 years ago

Commit d91756c1 parent 41e00581 file · +1 −0Browse files

Unified · Split

libavfilter/src_movie.c+1−0
@@ -344,6 +344,7 @@ static av_cold void movie_uninit(AVFilterContext *ctx) · 343 unmodified lines
344 }344 }
345 av_freep(&movie->st);345 av_freep(&movie->st);
346 av_freep(&movie->out_index);346 av_freep(&movie->out_index);
347 av_packet_unref(&movie->pkt);
347 if (movie->format_ctx)348 if (movie->format_ctx)
348 avformat_close_input(&movie->format_ctx);349 avformat_close_input(&movie->format_ctx);
349}350}

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t