Fix sxp2xml translation to handle maxmem.

Signed-off-by: Tom Wilkie <tom.wilkie@gmail.com>
This commit is contained in:
Ewan Mellor committed 2007-03-20 15:15:37 +00:00
1 parent 9e9090601c
commit f6c7de277c
1 file changed
+5 -1
+5 -1
View File
@@ -513,11 +513,15 @@ class sxp2xml:
memory_str = str(int(
get_child_by_name(config, "memory"))*1024*1024)
memory.attributes["static_min"] = memory_str
memory.attributes["static_min"] = str(0)
memory.attributes["static_max"] = memory_str
memory.attributes["dynamic_min"] = memory_str
memory.attributes["dynamic_max"] = memory_str
if get_child_by_name(config, "maxmem"):
memory.attributes["static_max"] = \
str(int(get_child_by_name(config, "maxmem")*1024*1024))
vm.appendChild(memory)
# And now the vbds
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.