Signed-off-by: Wei Liu <wei.l...@citrix.com> --- tools/libxl/libxl_x86.c | 6 ++++++ 1 file changed, 6 insertions(+)
diff --git a/tools/libxl/libxl_x86.c b/tools/libxl/libxl_x86.c index 8cd15ca..6be9b1b 100644 --- a/tools/libxl/libxl_x86.c +++ b/tools/libxl/libxl_x86.c @@ -311,6 +311,11 @@ int libxl__arch_domain_create(libxl__gc *gc, libxl_domain_config *d_config, t = time(NULL); tm = localtime(&t); + if (!tm) { + ret = ERROR_FAIL; + goto out; + } + rtc_timeoffset += tm->tm_gmtoff; } @@ -335,6 +340,7 @@ int libxl__arch_domain_create(libxl__gc *gc, libxl_domain_config *d_config, } } +out: return ret; } -- 1.9.1 _______________________________________________ Xen-devel mailing list Xen-devel@lists.xen.org http://lists.xen.org/xen-devel