From b0c34331c79b6b8f066f80f455d7043a1b19a78e Mon Sep 17 00:00:00 2001 From: Cleanbit25 Date: Sun, 30 Jun 2024 13:51:34 +0200 Subject: [PATCH] [bugfix] Print required options hint for vmaf tool correctly This seems to be a copy and paste bug. Calling "vmaf" with only -r option prints "could not open file: (null)". Instead it should print the correct usage hint. --- libvmaf/tools/cli_parse.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libvmaf/tools/cli_parse.c b/libvmaf/tools/cli_parse.c index 73a569100..4382b0936 100644 --- a/libvmaf/tools/cli_parse.c +++ b/libvmaf/tools/cli_parse.c @@ -507,7 +507,7 @@ void cli_parse(const int argc, char *const *const argv, settings->output_fmt = VMAF_OUTPUT_FORMAT_XML; if (!settings->path_ref) usage(argv[0], "Reference .y4m or .yuv (-r/--reference) is required"); - if (!settings->path_ref) + if (!settings->path_dist) usage(argv[0], "Distorted .y4m or .yuv (-d/--distorted) is required"); if (settings->use_yuv && !(settings->width && settings->height && settings->pix_fmt && settings->bitdepth))