mirror of
https://github.com/xen-project/xen.git
synced 2026-10-29 18:50:05 +01:00
Fix typo and make create send proper bools
signed-off-by: Tom Wilkie <tom.wilkie@gmail.com>
This commit is contained in:
1 parent
e17fb5f345
commit
60bd45b963
2 files changed
+5
-5
No files matched your search
@@ -95,7 +95,7 @@
|
||||
src %URI; #REQUIRED
|
||||
type %VDI_TYPE; #REQUIRED
|
||||
size CDATA #REQUIRED
|
||||
shareable CDATA #REQUIRED
|
||||
sharable CDATA #REQUIRED
|
||||
read_only CDATA #REQUIRED>
|
||||
|
||||
<!ELEMENT name (label,
|
||||
|
||||
@@ -212,8 +212,8 @@ class xenapi_create:
|
||||
"SR": self.DEFAULT_STORAGE_REPOSITORY,
|
||||
"virtual_size": vdi.attributes["size"].value,
|
||||
"type": vdi.attributes["type"].value,
|
||||
"shareable": vdi.attributes["shareable"].value,
|
||||
"read_only": vdi.attributes["read_only"].value,
|
||||
"sharable": bool(vdi.attributes["sharable"].value),
|
||||
"read_only": bool(vdi.attributes["read_only"].value),
|
||||
"other_config": {"location":
|
||||
vdi.attributes["src"].value}
|
||||
}
|
||||
@@ -629,10 +629,10 @@ class sxp2xml:
|
||||
vdi.attributes["src"] = src
|
||||
vdi.attributes["read_only"] \
|
||||
= (get_child_by_name(vbd_sxp, "mode") != "w") \
|
||||
and "true" or "false"
|
||||
and "True" or "False"
|
||||
vdi.attributes["size"] = '-1'
|
||||
vdi.attributes["type"] = "system"
|
||||
vdi.attributes["shareable"] = "false"
|
||||
vdi.attributes["sharable"] = "False"
|
||||
vdi.attributes["name"] = name
|
||||
|
||||
vdi.appendChild(self.make_name_tag(name, document))
|
||||
|
||||