From 88cfe47614f18b031b659c13951190405a0c8d31 Mon Sep 17 00:00:00 2001 From: wm4 Date: Thu, 15 Nov 2012 12:40:39 +0100 Subject: input: silence warning if input.conf is missing It's silly to print a warning if an optional config file is missing. Don't print anything at the default message level if an input config is not found. Unfortunately, the behavior is the same for explicitly passed input config files (with --input=conf=file.conf). --- core/input/input.c | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'core') diff --git a/core/input/input.c b/core/input/input.c index 115d181e69..210aa54a4f 100644 --- a/core/input/input.c +++ b/core/input/input.c @@ -1722,6 +1722,10 @@ static int parse_config(struct input_ctx *ictx, bool builtin, bstr data, static int parse_config_file(struct input_ctx *ictx, char *file) { + if (!mp_path_exists(file)) { + mp_msg(MSGT_INPUT, MSGL_V, "Input config file %s missing.\n", file); + return 0; + } stream_t *s = open_stream(file, NULL, NULL); if (!s) { mp_msg(MSGT_INPUT, MSGL_V, "Can't open input config file %s.\n", file); -- cgit v1.2.3