ia64/xen-unstable
changeset 8869:18fa851b6dc6
When xc_linux_build fails without a meaninful errno, force errno to EINVAL
avoid message "Error creating domain: (0, 'Error')" in the case
domU version is too old or too new.
Signed-off-by: Vincent Hanquez <vincent@xensource.com>
avoid message "Error creating domain: (0, 'Error')" in the case
domU version is too old or too new.
Signed-off-by: Vincent Hanquez <vincent@xensource.com>
author | vhanquez@kneesa.uk.xensource.com |
---|---|
date | Thu Feb 16 16:19:38 2006 +0000 (2006-02-16) |
parents | a543a4778a7d |
children | 2b0078f771cc |
files | tools/python/xen/lowlevel/xc/xc.c |
line diff
1.1 --- a/tools/python/xen/lowlevel/xc/xc.c Thu Feb 16 16:46:21 2006 +0100 1.2 +++ b/tools/python/xen/lowlevel/xc/xc.c Thu Feb 16 16:19:38 2006 +0000 1.3 @@ -347,9 +347,11 @@ static PyObject *pyxc_linux_build(XcObje 1.4 if ( xc_linux_build(self->xc_handle, dom, image, 1.5 ramdisk, cmdline, flags, 1.6 store_evtchn, &store_mfn, 1.7 - console_evtchn, &console_mfn) != 0 ) 1.8 + console_evtchn, &console_mfn) != 0 ) { 1.9 + if (!errno) 1.10 + errno = EINVAL; 1.11 return PyErr_SetFromErrno(xc_error); 1.12 - 1.13 + } 1.14 return Py_BuildValue("{s:i,s:i}", 1.15 "store_mfn", store_mfn, 1.16 "console_mfn", console_mfn);