]> git.ipfire.org Git - thirdparty/util-linux.git/commitdiff
fdisk: fix fdisk_sgi_set_bootfile return value
authormr-bronson <ghbugs@toeai.com>
Sun, 18 Aug 2024 01:06:44 +0000 (01:06 +0000)
committermr-bronson <ghbugs@toeai.com>
Sun, 18 Aug 2024 01:09:13 +0000 (01:09 +0000)
Supposed to be '0 on success, <0 on error'.

libfdisk/src/sgi.c

index 2293a20b4080e5a1bab672237ad98ce2d6c395c6..71abedd3f9b9a3a9f46926141d34fde9a35119dc 100644 (file)
@@ -447,8 +447,10 @@ int fdisk_sgi_set_bootfile(struct fdisk_context *cxt)
        if (rc == 0)
                rc = sgi_check_bootfile(cxt, name);
        if (rc) {
-               if (rc == 1)
+               if (rc == 1) {
                        fdisk_info(cxt, _("Boot file is unchanged."));
+                       rc = 0;
+               }
                goto done;
        }