Blame SOURCES/0125-RHBZ-1153832-kpartx-delete.patch

f20720
---
f20720
 kpartx/kpartx.c |    4 ++--
f20720
 1 file changed, 2 insertions(+), 2 deletions(-)
f20720
f20720
Index: multipath-tools-130222/kpartx/kpartx.c
f20720
===================================================================
f20720
--- multipath-tools-130222.orig/kpartx/kpartx.c
f20720
+++ multipath-tools-130222/kpartx/kpartx.c
f20720
@@ -409,7 +409,7 @@ main(int argc, char **argv){
f20720
 			break;
f20720
 
f20720
 		case DELETE:
f20720
-			for (j = n-1; j >= 0; j--) {
f20720
+			for (j = MAXSLICES-1; j >= 0; j--) {
f20720
 				if (safe_sprintf(partname, "%s%s%d",
f20720
 					     mapname, delim, j+1)) {
f20720
 					fprintf(stderr, "partname too small\n");
f20720
@@ -417,7 +417,7 @@ main(int argc, char **argv){
f20720
 				}
f20720
 				strip_slash(partname);
f20720
 
f20720
-				if (!slices[j].size || !dm_map_present(partname))
f20720
+				if (!dm_map_present(partname))
f20720
 					continue;
f20720
 
f20720
 				if (!dm_simplecmd(DM_DEVICE_REMOVE, partname,