[FFmpeg-devel] [PATCH 2/2] frame: make av_frame_remove_side_data return early

quinkblack at foxmail.com quinkblack at foxmail.com
Fri Oct 25 08:00:02 EEST 2019


From: Zhao Zhili <zhilizhao at tencent.com>

---
 libavutil/frame.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/libavutil/frame.c b/libavutil/frame.c
index bb20e99331..9edf971c55 100644
--- a/libavutil/frame.c
+++ b/libavutil/frame.c
@@ -825,6 +825,7 @@ void av_frame_remove_side_data(AVFrame *frame, enum AVFrameSideDataType type)
             free_side_data(&frame->side_data[i]);
             frame->side_data[i] = frame->side_data[frame->nb_side_data - 1];
             frame->nb_side_data--;
+            return;
         }
     }
 }
-- 
2.22.0





More information about the ffmpeg-devel mailing list