Commit 7e4f32f4 authored by Michael Niedermayer's avatar Michael Niedermayer

avutil/frame: Disallow zero sized frame side data

There should be no case that needs this and its a potential for
creating corner cases
Signed-off-by: 's avatarMichael Niedermayer <michael@niedermayer.cc>
parent 5804201c
......@@ -668,6 +668,8 @@ AVFrameSideData *av_frame_new_side_data(AVFrame *frame,
enum AVFrameSideDataType type,
int size)
{
if (size <= 0)
return NULL;
return frame_new_side_data(frame, type, av_buffer_alloc(size));
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment