Fixes: CID1559901 Resource leak
Unified · Split
| @@ -237,8 +237,10 @@ static int output_frame(AVFilterLink *outlink) · 236 unmodified lines | ||
| 237 | 237 | |
| 238 | 238 | // set correct timestamps and props as long as there is proper input |
| 239 | 239 | ret = av_frame_copy_props(dst, s->input); |
| 240 | − if (ret < 0) | |
| 240 | + if (ret < 0) { | |
| 241 | + av_frame_free(&dst); | |
| 241 | 242 | return ret; |
| 243 | + } | |
| 242 | 244 | |
| 243 | 245 | // discard frame at the top of the list since it has been fully processed |
| 244 | 246 | list_remove_head(s); |