From 46e7eac1216003df98fe9d8166f9fe52f76192d6 Mon Sep 17 00:00:00 2001 From: Karel Zak Date: Thu, 21 Mar 2013 08:12:35 +0100 Subject: [PATCH] fdisk: remove unwanted operator [smatch scan] Reported-by: Sami Kerola Signed-off-by: Karel Zak --- fdisks/fdisksunlabel.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/fdisks/fdisksunlabel.c b/fdisks/fdisksunlabel.c index 66f459bf53..2226f4c778 100644 --- a/fdisks/fdisksunlabel.c +++ b/fdisks/fdisksunlabel.c @@ -314,7 +314,7 @@ static int sun_toggle_partition_flag(struct fdisk_context *cxt, size_t i, unsign assert(cxt->label); assert(fdisk_is_disklabel(cxt, SUN)); - if (!i >= cxt->label->nparts_max) + if (i >= cxt->label->nparts_max) return -EINVAL; sunlabel = self_disklabel(cxt); -- 2.47.3