Blame SOURCES/efibootmgr-0.5.4-fix-disk-minor-number-discovery.patch

8dd33d
From f9f4ee75ad745637a47bf17ed968101b1ffbcc1d Mon Sep 17 00:00:00 2001
8dd33d
From: Matt Domsch <Matt_Domsch@dell.com>
8dd33d
Date: Thu, 23 Jul 2009 14:20:19 -0500
8dd33d
Subject: [PATCH 4/5] fix disk minor number discovery
8dd33d
8dd33d
Raymund Will noted disk_info_from_fd() incorrectly used logical &&
8dd33d
instead of bitwise & when obtaining the minor number.
8dd33d
8dd33d
Reported in https://bugzilla.novell.com/show_bug.cgi?id=524529#c1
8dd33d
---
8dd33d
 src/lib/disk.c | 2 +-
8dd33d
 1 file changed, 1 insertion(+), 1 deletion(-)
8dd33d
8dd33d
diff --git a/src/lib/disk.c b/src/lib/disk.c
8dd33d
index ebfe619..8ad590b 100644
8dd33d
--- a/src/lib/disk.c
8dd33d
+++ b/src/lib/disk.c
8dd33d
@@ -55,7 +55,7 @@ disk_info_from_fd(int fd,
8dd33d
 		return 1;
8dd33d
 	}
8dd33d
 	major = buf.st_dev >> 8;
8dd33d
-	minor = buf.st_dev && 0xFF;
8dd33d
+	minor = buf.st_dev & 0xFF;
8dd33d
 
8dd33d
 	/* IDE disks can have up to 64 partitions, or 6 bits worth,
8dd33d
 	 * and have one bit for the disk number.
8dd33d
-- 
8dd33d
1.8.0
8dd33d