Fix typo and make create send proper bools

signed-off-by: Tom Wilkie <tom.wilkie@gmail.com>
This commit is contained in:
Tom Wilkie committed 2007-04-12 11:31:17 +01:00
1 parent e17fb5f345
commit 60bd45b963
2 files changed
+5 -5

No files matched your search

+1 -1
View File
@@ -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,
+4 -4
View File
@@ -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))
Reference in new issue
Block a user
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.