[Spice-devel] [spice PATCH 27/55] smartcard: fix PIPE_ITEMs enum indexing

Yonit Halperin yhalperi at redhat.com
Wed Aug 15 00:56:07 PDT 2012


The enum should start from PIPE_ITEM_TYPE_CHANNEL_BASE, otherwise,
PIPE_ITEM_TYPE_ERROR is handled like PIPE_ITEM_TYPE_SET_ACK.
---
 server/smartcard.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/server/smartcard.c b/server/smartcard.c
index 44a3fae..bbd6826 100644
--- a/server/smartcard.c
+++ b/server/smartcard.c
@@ -66,7 +66,7 @@ struct SmartCardDeviceState {
 };
 
 enum {
-    PIPE_ITEM_TYPE_ERROR=1,
+    PIPE_ITEM_TYPE_ERROR = PIPE_ITEM_TYPE_CHANNEL_BASE,
     PIPE_ITEM_TYPE_MSG,
 };
 
-- 
1.7.7.6



More information about the Spice-devel mailing list