WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-changelog

[Xen-changelog] [xen-unstable] libxenlight: initialize enum to 1, to pre

To: xen-changelog@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-changelog] [xen-unstable] libxenlight: initialize enum to 1, to prevent defaulting to the 0
From: Xen patchbot-unstable <patchbot-unstable@xxxxxxxxxxxxxxxxxxx>
Date: Thu, 14 Jan 2010 02:20:16 -0800
Delivery-date: Thu, 14 Jan 2010 02:20:19 -0800
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
List-help: <mailto:xen-changelog-request@lists.xensource.com?subject=help>
List-id: BK change log <xen-changelog.lists.xensource.com>
List-post: <mailto:xen-changelog@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/mailman/listinfo/xen-changelog>, <mailto:xen-changelog-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/mailman/listinfo/xen-changelog>, <mailto:xen-changelog-request@lists.xensource.com?subject=unsubscribe>
Reply-to: xen-devel@xxxxxxxxxxxxxxxxxxx
Sender: xen-changelog-bounces@xxxxxxxxxxxxxxxxxxx
# HG changeset patch
# User Keir Fraser <keir.fraser@xxxxxxxxxx>
# Date 1263462055 0
# Node ID 94442ca0423d34d2618ce76de196a42ef995873a
# Parent  517364d0823de08b04d1f411752993ffa7bb84be
libxenlight: initialize enum to 1, to prevent defaulting to the 0
values when structure when not properly initialized by the client.

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

diff -r 517364d0823d -r 94442ca0423d tools/libxl/libxl.h
--- a/tools/libxl/libxl.h       Thu Jan 14 09:40:01 2010 +0000
+++ b/tools/libxl/libxl.h       Thu Jan 14 09:40:55 2010 +0000
@@ -104,7 +104,7 @@ typedef struct {
 } libxl_domain_suspend_info;
 
 typedef enum {
-    XENFV,
+    XENFV = 1,
     XENPV,
 } libxl_qemu_machine_type;
 
@@ -169,7 +169,7 @@ typedef struct {
 } libxl_device_console;
 
 typedef enum {
-    PHYSTYPE_QCOW,
+    PHYSTYPE_QCOW = 1,
     PHYSTYPE_QCOW2,
     PHYSTYPE_VHD,
     PHYSTYPE_AIO,
@@ -189,7 +189,7 @@ typedef struct {
 } libxl_device_disk;
 
 typedef enum {
-    NICTYPE_IOEMU,
+    NICTYPE_IOEMU = 1,
     NICTYPE_VIF,
 } libxl_nic_type;
 
diff -r 517364d0823d -r 94442ca0423d tools/libxl/libxl_internal.h
--- a/tools/libxl/libxl_internal.h      Thu Jan 14 09:40:01 2010 +0000
+++ b/tools/libxl/libxl_internal.h      Thu Jan 14 09:40:55 2010 +0000
@@ -59,7 +59,7 @@ void xl_log(struct libxl_ctx *ctx, int e
 
 
 typedef enum {
-    DEVICE_VIF,
+    DEVICE_VIF = 1,
     DEVICE_VBD,
     DEVICE_TAP,
     DEVICE_PCI,

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

<Prev in Thread] Current Thread [Next in Thread>
  • [Xen-changelog] [xen-unstable] libxenlight: initialize enum to 1, to prevent defaulting to the 0, Xen patchbot-unstable <=