[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Xen-devel] [PATCH] [Xen-API] Patch for fixing the rtc/timeoffset entry




Keir Fraser <Keir.Fraser@xxxxxxxxxxxx> wrote on 05/07/2007 09:01:59 AM:

> On 5/5/07 15:42, "Stefan Berger" <stefanb@xxxxxxxxxx> wrote:
>
> > This patch rewrites the rtc/timeoffset entry so the VM's record can be
> > retrieved with the Java xmlrpc library. If the entry is 'None' it upsets
> > the xmlrpc parser. This fixes it, though maybe there's a better place in
> > xend to place similar code.
>
> Can't the second argument to vm_details.get() be changed to "0"? If not,
> could you just do 'foo = vm_details.get(...) or "0"'?


The problem is that the 'get' only falls back to the default (currently passed as '0'), if the member of the dictionary is not set at all. Unfortunately the member has the value 'None'. Probably the value "0" should be assigned in the initialization of the dictionary.

   Stefan

>
>  -- Keir
>
>
_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel

 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.