Skip to content
Snippets Groups Projects
Commit 617814b4 authored by Federico Tomassetti's avatar Federico Tomassetti Committed by Vittorio Giovara
Browse files

buffersrc: Fix resource leak on error


Bug-Id: CID 1267902
CC: libav-stable@libav.org
Signed-off-by: default avatarVittorio Giovara <vittorio.giovara@gmail.com>
parent 336d2f09
No related branches found
No related tags found
No related merge requests found
...@@ -195,6 +195,7 @@ do { \ ...@@ -195,6 +195,7 @@ do { \
ref_out = av_buffer_create(data, data_size, compat_unref_buffer, \ ref_out = av_buffer_create(data, data_size, compat_unref_buffer, \
dummy_ref, 0); \ dummy_ref, 0); \
if (!ref_out) { \ if (!ref_out) { \
av_freep(&dummy_ref); \
av_frame_unref(frame); \ av_frame_unref(frame); \
ret = AVERROR(ENOMEM); \ ret = AVERROR(ENOMEM); \
goto fail; \ goto fail; \
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment