Whether failed or not, the block of codes labeled with fail should be always run to ensure the av_free(kernel_def) is executed.
Showing the changes to libavfilter (1 of 1 file). Show all
Unified · Split
| @@ -296,8 +296,6 @@ static av_cold int init_filter(AVFilterContext *ctx, AVFrame *in) · 295 unmodified lines | ||
| 296 | 296 | |
| 297 | 297 | s->initialized = 1; |
| 298 | 298 | |
| 299 | − return 0; | |
| 300 | − | |
| 301 | 299 | fail: |
| 302 | 300 | av_free(kernel_def); |
| 303 | 301 | return err; |