Dan Kenigsberg has posted comments on this change.
Change subject: Handle spaces in device names using lvm filter
......................................................................
Patch Set 5: I would prefer that you didn't submit this
(1 inline comment)
....................................................
File vdsm/storage/lvm.py
Line 133: devs = []
Line 134: for dev in devList:
Line 135: strippedDev = dev.strip()
Line 136: if strippedDev:
Line 137: devs.append(strippedDev.encode("string_escape").
again: encode() works here by pure chance. you need decode() in order to
convert multipath-encoded device names to raw chars.
Also, I do not understand why you ignore the risk of having the pipe sign or a
double quote in a device name.
This issue should better be solved properly, and be unit-tested.
Line 138: replace(' ', r'\\\\x20'))
Line 139: filt = '|'.join(devs)
Line 140: if len(filt) > 0:
Line 141: filt = "'a%" + filt + "%', "
--
To view, visit http://gerrit.ovirt.org/9191
To unsubscribe, visit http://gerrit.ovirt.org/settings
Gerrit-MessageType: comment
Gerrit-Change-Id: I1efb6dfd30c0999f14c413fff778213b247a178f
Gerrit-PatchSet: 5
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Yeela Kaplan <[email protected]>
Gerrit-Reviewer: Ayal Baron <[email protected]>
Gerrit-Reviewer: Dan Kenigsberg <[email protected]>
Gerrit-Reviewer: Eduardo <[email protected]>
Gerrit-Reviewer: Federico Simoncelli <[email protected]>
Gerrit-Reviewer: Igor Lvovsky <[email protected]>
Gerrit-Reviewer: Mark Wu <[email protected]>
Gerrit-Reviewer: Shu Ming <[email protected]>
Gerrit-Reviewer: Yeela Kaplan <[email protected]>
Gerrit-Reviewer: oVirt Jenkins CI Server
_______________________________________________
vdsm-patches mailing list
[email protected]
https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches