Change in vdsm[master]: vm: avoid duplicate import

fromani at redhat.com fromani at redhat.com
Tue Aug 12 07:32:42 UTC 2014


Francesco Romani has uploaded a new change for review.

Change subject: vm: avoid duplicate import
......................................................................

vm: avoid duplicate import

Vm._getVmPolicy added another minidom import just to use parseString.
There is no need for it since we already imported it as _domParseStr
from a long time.

Change-Id: I000b19bb46cd140372492d552f27a25424dd97e8
Signed-off-by: Francesco Romani <fromani at redhat.com>
---
M vdsm/virt/vm.py
1 file changed, 1 insertion(+), 2 deletions(-)


  git pull ssh://gerrit.ovirt.org:29418/vdsm refs/changes/80/31380/1

diff --git a/vdsm/virt/vm.py b/vdsm/virt/vm.py
index aa177b9..1ca2e0e 100644
--- a/vdsm/virt/vm.py
+++ b/vdsm/virt/vm.py
@@ -28,7 +28,6 @@
 import tempfile
 import threading
 import time
-import xml.dom.minidom
 import uuid
 
 # 3rd party libs imports
@@ -3417,7 +3416,7 @@
                 self.log.exception("getVmPolicy failed")
                 return None
 
-        metadata = xml.dom.minidom.parseString(metadata_xml)
+        metadata = _domParseStr(metadata_xml)
         return metadata.getElementsByTagName("qos")[0]
 
     def _findDeviceByNameOrPath(self, device_name, device_path):


-- 
To view, visit http://gerrit.ovirt.org/31380
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I000b19bb46cd140372492d552f27a25424dd97e8
Gerrit-PatchSet: 1
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Francesco Romani <fromani at redhat.com>


More information about the vdsm-patches mailing list