sws_freeContext have check the NULL pointer, so don't need to check NULL before sws_freeContext.
Unified · Split
| @@ -286,9 +286,7 @@ static av_cold void uninit(AVFilterContext *context) · 285 unmodified lines | |||
| 286 | } | 286 | } |
| 287 | 287 | ||
| 288 | for (i = 0; i < 3; ++i){ | 288 | for (i = 0; i < 3; ++i){ |
| 289 | if (sr_context->sws_contexts[i]){ | 289 | sws_freeContext(sr_context->sws_contexts[i]); |
| 290 | sws_freeContext(sr_context->sws_contexts[i]); | ||
| 291 | } | ||
| 292 | } | 290 | } |
| 293 | } | 291 | } |
| 294 | 292 | ||