From 0b9ee8e7ea62ecb8e169dd764fc1ace2410262a2 Mon Sep 17 00:00:00 2001 From: Martin Pulec Date: Tue, 14 Nov 2023 16:43:20 +0100 Subject: [PATCH] get_video_desc_from_string: print error if unknown Print an error if unknown mode was given, which could give the user a guidance what is wrong, eg.: `uv -t testcard:mode=bogus` outputted just`[testcard] Wrong video size, given: 0x0`, which isn't much helpful. Now it outputs also `[video] Unrecognized video mode: bogus` --- src/video.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/src/video.cpp b/src/video.cpp index 418e5933e..07b7b0756 100644 --- a/src/video.cpp +++ b/src/video.cpp @@ -350,6 +350,7 @@ struct video_desc get_video_desc_from_string(const char *string) ret.height = 2160; } if (ret.width == 0) { + MSG(ERROR, "Unrecognized video mode: %s\n", string); return {}; } ret.fps = parse_fps(string, ret.interlacing == INTERLACED_MERGED);