Change: Expected 7 arguments, but only %d found in '%s'\n to: Expected 7 arguments, but %d found in '%s'\n as the user may provide more than 7 arguments, in that case the error is not misleading.
Showing the changes to libavfilter (1 of 1 file). Show all
Unified · Split
| @@ -120,7 +120,7 @@ static av_cold int init(AVFilterContext *ctx, const char *args, void *opaque) · 119 unmodified lines | ||
| 120 | 120 | (n = sscanf(args, "%d:%d:%127[^:]:%d:%d:%d:%d", &c->w, &c->h, pix_fmt_str, |
| 121 | 121 | &c->time_base.num, &c->time_base.den, |
| 122 | 122 | &c->pixel_aspect.num, &c->pixel_aspect.den)) != 7) { |
| 123 | − av_log(ctx, AV_LOG_ERROR, "Expected 7 arguments, but only %d found in '%s'\n", n, args); | |
| 123 | + av_log(ctx, AV_LOG_ERROR, "Expected 7 arguments, but %d found in '%s'\n", n, args); | |
| 124 | 124 | return AVERROR(EINVAL); |
| 125 | 125 | } |
| 126 | 126 | if ((c->pix_fmt = av_get_pix_fmt(pix_fmt_str)) == PIX_FMT_NONE) { |