* commit '42c7c61ab25809620b8c8809b3da73e25f5bbaaf': avfiltergraph: replace AVFilterGraph.filter_count with nb_filters Conflicts: doc/APIchanges libavfilter/avfiltergraph.c libavfilter/avfiltergraph.h libavfilter/graphparser.c libavfilter/version.h
Showing the changes to libavfilter/graphparser.c (1 of 7 files). Show all
Unified · Split
| @@ -436,8 +436,8 @@ int avfilter_graph_parse2(AVFilterGraph *graph, const char *filters, · 435 unmodified lines | ||
| 436 | 436 | return 0; |
| 437 | 437 | |
| 438 | 438 | fail:end: |
| 439 | − for (; graph->filter_count > 0; graph->filter_count--) | |
| 440 | − avfilter_free(graph->filters[graph->filter_count - 1]); | |
| 439 | + for (; graph->nb_filters > 0; graph->nb_filters--) | |
| 440 | + avfilter_free(graph->filters[graph->nb_filters - 1]); | |
| 441 | 441 | av_freep(&graph->filters); |
| 442 | 442 | avfilter_inout_free(&open_inputs); |
| 443 | 443 | avfilter_inout_free(&open_outputs); |
| @@ -504,8 +504,8 @@ int avfilter_graph_parse(AVFilterGraph *graph, const char *filters, · 60 unmodified lines | ||
| 504 | 504 | |
| 505 | 505 | fail: |
| 506 | 506 | if (ret < 0) { |
| 507 | − for (; graph->filter_count > 0; graph->filter_count--) | |
| 508 | − avfilter_free(graph->filters[graph->filter_count - 1]); | |
| 507 | + for (; graph->nb_filters > 0; graph->nb_filters--) | |
| 508 | + avfilter_free(graph->filters[graph->nb_filters - 1]); | |
| 509 | 509 | av_freep(&graph->filters); |
| 510 | 510 | } |
| 511 | 511 | avfilter_inout_free(&inputs); |
| @@ -591,8 +591,8 @@ end: · 79 unmodified lines | ||
| 591 | 591 | avfilter_inout_free(&curr_inputs); |
| 592 | 592 | |
| 593 | 593 | if (ret < 0) { |
| 594 | − for (; graph->filter_count > 0; graph->filter_count--) | |
| 595 | − avfilter_free(graph->filters[graph->filter_count - 1]); | |
| 594 | + for (; graph->nb_filters > 0; graph->nb_filters--) | |
| 595 | + avfilter_free(graph->filters[graph->nb_filters - 1]); | |
| 596 | 596 | av_freep(&graph->filters); |
| 597 | 597 | } |
| 598 | 598 | return ret; |