[PATCH 01/31] libmultipath: fix partition_delimiter config option

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



The partition_delimiter setting was effecitvely ignored. Fix it.

Fixes: 95bf339bb9d7 "correctly set partition delimiter on rename"
Signed-off-by: Martin Wilck <mwilck@xxxxxxxx>
---
 libmultipath/devmapper.c | 10 ++++++----
 1 file changed, 6 insertions(+), 4 deletions(-)

diff --git a/libmultipath/devmapper.c b/libmultipath/devmapper.c
index 3b41a483..e701e806 100644
--- a/libmultipath/devmapper.c
+++ b/libmultipath/devmapper.c
@@ -1351,10 +1351,12 @@ dm_rename_partmaps (const char * old, char * new, char *delim)
 
 	if (delim)
 		rd.delim = delim;
-	if (isdigit(new[strlen(new)-1]))
-		rd.delim = "p";
-	else
-		rd.delim = "";
+	else {
+		if (isdigit(new[strlen(new)-1]))
+			rd.delim = "p";
+		else
+			rd.delim = "";
+	}
 	return do_foreach_partmaps(old, rename_partmap, &rd);
 }
 
-- 
2.14.0

--
dm-devel mailing list
dm-devel@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/dm-devel



[Index of Archives]     [DM Crypt]     [Fedora Desktop]     [ATA RAID]     [Fedora Marketing]     [Fedora Packaging]     [Fedora SELinux]     [Yosemite Discussion]     [KDE Users]     [Fedora Docs]

  Powered by Linux