From mboxrd@z Thu Jan 1 00:00:00 1970 From: Gerd Hoffmann Subject: [patch 2/6] Add more xc_error_code values. Date: Thu, 25 Jan 2007 17:19:18 +0100 Message-ID: <20070125161926.510246000@suse.de> References: <20070125161916.736076000@suse.de> Return-path: Content-Disposition: inline; filename=tools-add-errors.diff List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xensource.com Errors-To: xen-devel-bounces@lists.xensource.com To: xen-devel@lists.xensource.com Cc: ack@xensource.com List-Id: xen-devel@lists.xenproject.org XC_INVALID_PARAM such as asking for features unsupported by either xen or guest kernel. XC_OUT_OF_MEMORY no comment ;) Signed-off-by: Gerd Hoffmann --- tools/libxc/xc_private.c | 4 ++++ tools/libxc/xenctrl.h | 2 ++ 2 files changed, 6 insertions(+) Index: build-32-unstable-12809/tools/libxc/xenctrl.h =================================================================== --- build-32-unstable-12809.orig/tools/libxc/xenctrl.h +++ build-32-unstable-12809/tools/libxc/xenctrl.h @@ -691,6 +691,8 @@ typedef enum { XC_ERROR_NONE = 0, XC_INTERNAL_ERROR = 1, XC_INVALID_KERNEL = 2, + XC_INVALID_PARAM = 3, + XC_OUT_OF_MEMORY = 4, } xc_error_code; #define XC_MAX_ERROR_MSG_LEN 1024 Index: build-32-unstable-12809/tools/libxc/xc_private.c =================================================================== --- build-32-unstable-12809.orig/tools/libxc/xc_private.c +++ build-32-unstable-12809/tools/libxc/xc_private.c @@ -45,6 +45,10 @@ const char *xc_error_code_to_desc(int co return "Internal error"; case XC_INVALID_KERNEL: return "Invalid kernel"; + case XC_INVALID_PARAM: + return "Invalid configuration"; + case XC_OUT_OF_MEMORY: + return "Out of memory"; } return "Unknown error code"; --