[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Xen-changelog] [xen-unstable] tools: Fix time offset when localtime=0
# HG changeset patch # User Keir Fraser <keir.fraser@xxxxxxxxxx> # Date 1274858131 -3600 # Node ID 15f4ead9e6861ba1180840ce99f5b7815cc3361d # Parent 611a36481e92c6ccd36fd12c7e63a66cd1dfe07a tools: Fix time offset when localtime=0 localtime can be stored in vm config as a string, resulting in incorrect calculation of rtc_timeoffset. Cast localtime to int to ensure rtc_timeoffset is calculated properly. Signed-off-by: Jim Fehlig <jfehlig@xxxxxxxxxx> --- tools/python/xen/xend/image.py | 2 +- 1 files changed, 1 insertion(+), 1 deletion(-) diff -r 611a36481e92 -r 15f4ead9e686 tools/python/xen/xend/image.py --- a/tools/python/xen/xend/image.py Wed May 26 08:14:51 2010 +0100 +++ b/tools/python/xen/xend/image.py Wed May 26 08:15:31 2010 +0100 @@ -129,7 +129,7 @@ class ImageHandler: self.dmargs = self.parseDeviceModelArgs(vmConfig) self.pid = None rtc_timeoffset = int(vmConfig['platform'].get('rtc_timeoffset', 0)) - if vmConfig['platform'].get('localtime', 0): + if int(vmConfig['platform'].get('localtime', 0)): if time.localtime(time.time())[8]: rtc_timeoffset -= time.altzone else: _______________________________________________ Xen-changelog mailing list Xen-changelog@xxxxxxxxxxxxxxxxxxx http://lists.xensource.com/xen-changelog
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |