[dm-devel] multipath bug and patch
James Shoemaker
james at dhlake.com
Thu Nov 3 18:34:17 UTC 2016
If a device returns an empty string for inquiry data the current
multipath tool ignores it on reload. I added the following patch and I can
hotplug these devices that don't return all the proper data.
diff --git a/libmultipath/util.c b/libmultipath/util.c
index ac0d1b2..045e660 100644
--- a/libmultipath/util.c
+++ b/libmultipath/util.c
@@ -17,6 +17,10 @@ strchop(char *str)
for (i=strlen(str)-1; i >=0 && isspace(str[i]); --i) ;
str[++i] = '\0';
+ if(strlen(str)==0)
+ {
+ strcpy(str,"none");
+ }
return strlen(str);
}
James Shoemaker
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://listman.redhat.com/archives/dm-devel/attachments/20161103/437987b7/attachment.htm>
More information about the dm-devel
mailing list