From: zsien Date: Mon, 10 May 2021 07:42:54 +0000 (+0800) Subject: bootctl: same entry path check case-insensitive X-Git-Tag: v249-rc1~245 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=5c2e5957678462d871c5c2ea5261becec5f8f80f;p=thirdparty%2Fsystemd.git bootctl: same entry path check case-insensitive Some motherboards convert the path to uppercase under certain circumstances (e.g. after booting into the Boot Menu in the ASUS ROG STRIX B350-F GAMING). --- diff --git a/src/boot/bootctl.c b/src/boot/bootctl.c index 34f0c14b44a..d89f4e9b59c 100644 --- a/src/boot/bootctl.c +++ b/src/boot/bootctl.c @@ -684,7 +684,11 @@ static bool same_entry(uint16_t id, sd_id128_t uuid, const char *path) { return false; if (!sd_id128_equal(uuid, ouuid)) return false; - if (!streq_ptr(path, opath)) + + /* Some motherboards convert the path to uppercase under certain circumstances + * (e.g. after booting into the Boot Menu in the ASUS ROG STRIX B350-F GAMING), + * so use case-insensitive checking */ + if (!strcaseeq_ptr(path, opath)) return false; return true;