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

[Xen-changelog] [xen-unstable] [XEND] Remove hard tabs from destroyDevice()



# HG changeset patch
# User atse@xxxxxxxxxxxxxxxxxxxxxxxx
# Node ID 332bdaab35fa1bd9ee7f7a117a847fffbda3cddd
# Parent  1db4e40b4d83b049f3d8b3a22485e0821e2bc1b4
[XEND] Remove hard tabs from destroyDevice()
Reported by Hollis Blanchard.

Signed-off-by: Alastair Tse <atse@xxxxxxxxxxxxx>
---
 tools/python/xen/xend/XendDomainInfo.py |   19 ++++++++++---------
 1 files changed, 10 insertions(+), 9 deletions(-)

diff -r 1db4e40b4d83 -r 332bdaab35fa tools/python/xen/xend/XendDomainInfo.py
--- a/tools/python/xen/xend/XendDomainInfo.py   Fri Sep 22 15:36:11 2006 +0100
+++ b/tools/python/xen/xend/XendDomainInfo.py   Fri Sep 22 15:56:19 2006 +0100
@@ -1098,15 +1098,16 @@ class XendDomainInfo:
     ## public:
 
     def destroyDevice(self, deviceClass, devid):
-       if type(devid) is str:
-           devicePath = '%s/device/%s' % (self.dompath, deviceClass)
-           for entry in xstransact.List(devicePath):
-               backend = xstransact.Read('%s/%s' % (devicePath, entry), 
"backend")
-               devName = xstransact.Read(backend, "dev")
-               if devName == devid:
-                   # We found the integer matching our devid, use it instead
-                   devid = entry
-                   break
+        if type(devid) is str:
+            devicePath = '%s/device/%s' % (self.dompath, deviceClass)
+            for entry in xstransact.List(devicePath):
+                backend = xstransact.Read('%s/%s' % (devicePath, entry),
+                                          "backend")
+                devName = xstransact.Read(backend, "dev")
+                if devName == devid:
+                    # We found the integer matching our devid, use it instead
+                    devid = entry
+                    break
         return self.getDeviceController(deviceClass).destroyDevice(devid)
 
 

_______________________________________________
Xen-changelog mailing list
Xen-changelog@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-changelog


 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.