Skip to contentSkip to conversation

kpartx bug fixes for dos extended partition [4/4]

PATCH Jun'ichi Nomura 1 participant 1 message Dec 5, 2005 Device mapper

lore
Share & tools
lore
#0 lore raw

This mail was not reached to dm-devel.
I'm resending this.

There is meaninglessly duplicated code in read_dos_pt(). It should be safe to remove it.

Thanks,
Nick

Duplicated for loop is non-sense.

kpartx/dos.c +0 -3
@@ -86,9 +86,6 @@ read_dos_pt(int fd, struct slice all, st
 
 	for (i=0; i<4; i++) {
 		memcpy(&p, bp + 0x1be + i * sizeof (p), sizeof (p));
-	}
-	for (i=0; i<4; i++) {
-		memcpy(&p, bp + 0x1be + i * sizeof (p), sizeof (p));
 		if (is_gpt(p.sys_type))
 			return 0;
 		if (i < ns) {