Commit 93afb338 authored by Ganesh Ajjanagadde's avatar Ganesh Ajjanagadde

lavfi/formats: fix segfault when allocation fails

This is a somewhat subtle failure that can occur when the realloc_array
fails in FORMATS_REF.
Signed-off-by: 's avatarGanesh Ajjanagadde <gajjanagadde@gmail.com>
parent 46cbb4c2
......@@ -445,7 +445,7 @@ do { \
do { \
int idx = -1; \
\
if (!*ref) \
if (!*ref || !(*ref)->refs) \
return; \
\
FIND_REF_INDEX(ref, idx); \
......
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