ia64/xen-unstable
changeset 6849:1585590ec474
More syntactic sugar.
Signed-off-by: Christian Limpach <Christian.Limpach@cl.cam.ac.uk>
Signed-off-by: Christian Limpach <Christian.Limpach@cl.cam.ac.uk>
author | cl349@firebug.cl.cam.ac.uk |
---|---|
date | Wed Sep 14 19:34:13 2005 +0000 (2005-09-14) |
parents | bc5dbfe729e0 |
children | 40e6dfad4eff |
files | tools/python/xen/xend/xenstore/xstransact.py |
line diff
1.1 --- a/tools/python/xen/xend/xenstore/xstransact.py Wed Sep 14 19:30:08 2005 +0000 1.2 +++ b/tools/python/xen/xend/xenstore/xstransact.py Wed Sep 14 19:34:13 2005 +0000 1.3 @@ -105,6 +105,8 @@ class xstransact: 1.4 return ret 1.5 1.6 def gather(self, *args): 1.7 + if len(args) and type(args[0]) != tuple: 1.8 + args = args, 1.9 ret = [] 1.10 for tup in args: 1.11 if len(tup) == 2: 1.12 @@ -122,6 +124,8 @@ class xstransact: 1.13 return ret 1.14 1.15 def store(self, *args): 1.16 + if len(args) and type(args[0]) != tuple: 1.17 + args = args, 1.18 for tup in args: 1.19 if len(tup) == 2: 1.20 (key, val) = tup