]> git.ipfire.org Git - thirdparty/util-linux.git/commitdiff
bits: fix return value check for cpulist_parse()
authorWanBingjiang <wanbingjiang@webray.com.cn>
Wed, 29 Apr 2026 02:19:57 +0000 (10:19 +0800)
committerWanBingjiang <wanbingjiang@webray.com.cn>
Thu, 7 May 2026 01:51:19 +0000 (09:51 +0800)
Signed-off-by: WanBingjiang <wanbingjiang@webray.com.cn>
text-utils/bits.c

index 03d5547e4a5c0575ae00b49730894da5bf75c5fa..7f2bac5f1aee4f4c22166fa72093aa41319f9cf8 100644 (file)
@@ -63,7 +63,7 @@ static void parse_mask_or_list(const char *cmdline_arg,
                if (cpumask_parse(arg, bits, size) < 0)
                        errx(EXIT_FAILURE, _("error: invalid bit mask: %s"), cmdline_arg);
        } else {
-               if (cpulist_parse(arg, bits, size, 1) < 0)
+               if (cpulist_parse(arg, bits, size, 1))
                        errx(EXIT_FAILURE, _("error: invalid bit list: %s"), cmdline_arg);
        }