[FFmpeg-devel] [PATCH 1/4] avutil/detection_bbox: fix the memory leak on error
lance.lmwang at gmail.com
lance.lmwang at gmail.com
Tue Sep 28 16:36:35 EEST 2021
From: Limin Wang <lance.lmwang at gmail.com>
Signed-off-by: Limin Wang <lance.lmwang at gmail.com>
---
libavutil/detection_bbox.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/libavutil/detection_bbox.c b/libavutil/detection_bbox.c
index 40711e6..d066567 100644
--- a/libavutil/detection_bbox.c
+++ b/libavutil/detection_bbox.c
@@ -61,6 +61,7 @@ AVDetectionBBoxHeader *av_detection_bbox_create_side_data(AVFrame *frame, uint32
}
if (!av_frame_new_side_data_from_buf(frame, AV_FRAME_DATA_DETECTION_BBOXES, buf)) {
+ av_freep(&header);
av_buffer_unref(&buf);
return NULL;
}
--
1.8.3.1
More information about the ffmpeg-devel
mailing list