Adam Litke has uploaded a new change for review.
Change subject: libvirtvm: Cast text to string when creating text node ......................................................................
libvirtvm: Cast text to string when creating text node
When creating a text node for a libvirt domain xml file, the content of the node is expected to be a string. To avoid errors in the xml file, cast the parameter to a string representation when creating the child node.
Change-Id: Id22db83062eaf85645c2d61c83f3f20943918413 Signed-off-by: Adam Litke agl@us.ibm.com --- M vdsm/libvirtvm.py 1 file changed, 1 insertion(+), 1 deletion(-)
git pull ssh://gerrit.ovirt.org:29418/vdsm refs/changes/32/7832/1
diff --git a/vdsm/libvirtvm.py b/vdsm/libvirtvm.py index 3306cc2..eaf899d 100644 --- a/vdsm/libvirtvm.py +++ b/vdsm/libvirtvm.py @@ -542,7 +542,7 @@
def appendChildWithText(self, childName, text): childNode = self.doc.createElement(childName) - textNode = self.doc.createTextNode(text) + textNode = self.doc.createTextNode(str(text)) childNode.appendChild(textNode) self.dom.appendChild(childNode)
-- To view, visit http://gerrit.ovirt.org/7832 To unsubscribe, visit http://gerrit.ovirt.org/settings
Gerrit-MessageType: newchange Gerrit-Change-Id: Id22db83062eaf85645c2d61c83f3f20943918413 Gerrit-PatchSet: 1 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Adam Litke agl@us.ibm.com