From: Lennart Poettering Date: Mon, 28 Jan 2019 16:32:04 +0000 (+0100) Subject: bootspec: use SYNTHETIC_ERRNO() at one more place X-Git-Tag: v242-rc1~218^2~44 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=46bba8a51cddc966a3ec853a7e4fbae8e58c5c77;p=thirdparty%2Fsystemd.git bootspec: use SYNTHETIC_ERRNO() at one more place --- diff --git a/src/shared/bootspec.c b/src/shared/bootspec.c index 410930e9cda..c60627e24c3 100644 --- a/src/shared/bootspec.c +++ b/src/shared/bootspec.c @@ -50,10 +50,8 @@ static int boot_entry_load(const char *path, BootEntry *entry) { assert(entry); c = endswith_no_case(path, ".conf"); - if (!c) { - log_error("Invalid loader entry filename: %s", path); - return -EINVAL; - } + if (!c) + return log_error_errno(SYNTHETIC_ERRNO(EINVAL), "Invalid loader entry filename: %s", path); b = basename(path); tmp.id = strndup(b, c - b);