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

[Xen-changelog] [xen-unstable] libxl: define errors as an enum instead of define random values.



# HG changeset patch
# User Keir Fraser <keir.fraser@xxxxxxxxxx>
# Date 1262177176 0
# Node ID c21ae3e20134a4fefbb9badf20eea8095751e9c5
# Parent  88e59cfb48de60b3bfd04c74e6ac230d061ae5b0
libxl: define errors as an enum instead of define random values.

Signed-off-by: Vincent Hanquez <vincent.hanquez@xxxxxxxxxxxxx>
---
 tools/libxl/libxl.h |   11 +++++++----
 1 files changed, 7 insertions(+), 4 deletions(-)

diff -r 88e59cfb48de -r c21ae3e20134 tools/libxl/libxl.h
--- a/tools/libxl/libxl.h       Wed Dec 30 12:45:41 2009 +0000
+++ b/tools/libxl/libxl.h       Wed Dec 30 12:46:16 2009 +0000
@@ -226,10 +226,13 @@ typedef struct  {
     bool power_mgmt;
 } libxl_device_pci;
 
-#define ERROR_FAIL (-2)
-#define ERROR_NI (-101)
-#define ERROR_NOMEM (-1032)
-#define ERROR_INVAL (-1245)
+enum {
+    ERROR_VERSION = -1,
+    ERROR_FAIL = -2,
+    ERROR_NI = -3,
+    ERROR_NOMEM = -4,
+    ERROR_INVAL = -5,
+};
 
 /* context functions */
 int libxl_ctx_init(struct libxl_ctx *ctx);

_______________________________________________
Xen-changelog mailing list
Xen-changelog@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-changelog


 


Rackspace

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