[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Xen-changelog] [xen-unstable] [XEND] Don't prepend '/dev/' to any absolute path.
# HG changeset patch # User Tim Deegan <tim.deegan@xxxxxxxxxxxxx> # Node ID 7c5d1c37943813a047a25866a36f21263693ffb8 # Parent 7894224d264b69bd5d6c1f374a54a5cbdadcce6d [XEND] Don't prepend '/dev/' to any absolute path. Check for '/' rather than '/dev/' when translating e.g. 'hda'->'/dev/hda' Signed-off-by: Tim Deegan <tim.deegan@xxxxxxxxxxxxx> --- tools/python/xen/util/blkif.py | 4 ++-- 1 files changed, 2 insertions(+), 2 deletions(-) diff -r 7894224d264b -r 7c5d1c379438 tools/python/xen/util/blkif.py --- a/tools/python/xen/util/blkif.py Thu Sep 21 14:58:01 2006 +0100 +++ b/tools/python/xen/util/blkif.py Thu Sep 21 15:00:50 2006 +0100 @@ -7,7 +7,7 @@ def expand_dev_name(name): def expand_dev_name(name): if not name: return name - if re.match( '^/dev/', name ): + if re.match( '^/', name ): return name else: return '/dev/' + name @@ -65,7 +65,7 @@ def blkdev_uname_to_file(uname): fn = None if uname.find(":") != -1: (typ, fn) = uname.split(":") - if typ == "phy" and not fn.startswith("/dev/"): + if typ == "phy" and not fn.startswith("/"): fn = "/dev/%s" %(fn,) return fn _______________________________________________ Xen-changelog mailing list Xen-changelog@xxxxxxxxxxxxxxxxxxx http://lists.xensource.com/xen-changelog
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |