ChangeSet 1.1473, 2005/05/19 22:14:26+01:00, akw27@xxxxxxxxxxxxxxxxxxxxxx
Merge arcadians.cl.cam.ac.uk:/auto/groups/xeno-xenod/BK/xeno.bk
into arcadians.cl.cam.ac.uk:/auto/anfs/nos1/akw27/xeno-clone/xeno.bk
Blkctl.py | 11 ++++-------
server/blkif.py | 2 +-
2 files changed, 5 insertions(+), 8 deletions(-)
diff -Nru a/tools/python/xen/xend/Blkctl.py b/tools/python/xen/xend/Blkctl.py
--- a/tools/python/xen/xend/Blkctl.py 2005-05-19 18:04:30 -04:00
+++ b/tools/python/xen/xend/Blkctl.py 2005-05-19 18:04:30 -04:00
@@ -4,11 +4,10 @@
import os.path
import sys
import string
+import xen.util.process
from xen.xend import XendRoot
-from xen.util.ip import _readline, _readlines
-
xroot = XendRoot.instance()
"""Where network control scripts live."""
@@ -39,8 +38,6 @@
script = os.path.join(SCRIPT_DIR, script)
args = [op] + string.split(dets, ':')
args = ' '.join(args)
- out = os.popen(script + ' ' + args)
-
- output = _readline(out)
- out.close()
- return string.rstrip(output)
+ ret = xen.util.process.runscript(script + ' ' + args)
+ if len(ret):
+ return ret.splitlines()[0]
diff -Nru a/tools/python/xen/xend/server/blkif.py
b/tools/python/xen/xend/server/blkif.py
--- a/tools/python/xen/xend/server/blkif.py 2005-05-19 18:04:30 -04:00
+++ b/tools/python/xen/xend/server/blkif.py 2005-05-19 18:04:30 -04:00
@@ -263,7 +263,7 @@
def check_mounted(self, name):
mode = blkif.mount_mode(name)
xd = XendRoot.get_component('xen.xend.XendDomain')
- for vm in xd.domains():
+ for vm in xd.list():
ctrl = vm.getDeviceController(self.getType(), error=False)
if (not ctrl): continue
for dev in ctrl.getDevices():
_______________________________________________
Xen-changelog mailing list
Xen-changelog@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-changelog
|