Huge thanks to our Platinum Members Endace and LiveAction,
and our Silver Member Veeam, for supporting the Wireshark Foundation and project.

Wireshark-dev: [Wireshark-dev] [PATCH] USB setup hdr

From: Paolo Abeni <paolo.abeni@xxxxxxxx>
Date: Wed, 11 Oct 2006 11:44:41 +0200
hello,

this patch reflect the changes into usb setup header from current
libpcap cvs.

Paolo

 
 
 --
 Email.it, the professional e-mail, gratis per te: http://www.email.it/f
 
 Sponsor:
 Ti piace la chitarra? Impara a suonarla senza fatica ed evitando tutti gli errori, con l'aiuto di un maestro professionista
 Clicca qui: http://adv.email.it/cgi-bin/foclick.cgi?mid=5144&d=11-10
Index: epan/dissectors/packet-usb.c
===================================================================
--- epan/dissectors/packet-usb.c	(revision 19488)
+++ epan/dissectors/packet-usb.c	(working copy)
@@ -51,11 +51,11 @@
 } usb_header_t;
 
 typedef struct usb_setup {
-  guint32 bmRequestType;
-  guint32 bRequest;
-  guint32 wValue;
-  guint32 wIndex;
-  guint32 wLength;
+  guint8 bmRequestType;
+  guint8 bRequest;
+  guint16 wValue;
+  guint16 wIndex;
+  guint16 wLength;
 } usb_setup_t;
 
 
@@ -162,23 +162,23 @@
                 "usb endpoint number", HFILL }},
 
         { &hf_usb_request_type,
-        { "Request Type", "usb.request_type", FT_UINT32, BASE_HEX, NULL, 0x0,
+        { "Request Type", "usb.setup.request_type", FT_UINT8, BASE_HEX, NULL, 0x0,
                 "", HFILL }},
 
         { &hf_usb_request,
-        { "Request", "usb.request", FT_UINT32, BASE_HEX, NULL, 0x0,
+        { "Request", "usb.setup.request", FT_UINT8, BASE_HEX, NULL, 0x0,
                 "", HFILL }},
 
         { &hf_usb_value,
-        { "value", "usb.value", FT_UINT32, BASE_HEX, NULL, 0x0,
+        { "value", "usb.setup.value", FT_UINT16, BASE_HEX, NULL, 0x0,
                 "", HFILL }},
 
         { &hf_usb_index,
-        { "Index", "usb.index", FT_UINT32, BASE_DEC, NULL, 0x0,
+        { "Index", "usb.setup.index", FT_UINT16, BASE_DEC, NULL, 0x0,
                 "", HFILL }},
 
         { &hf_usb_length,
-        { "Length", "usb.length", FT_UINT32, BASE_DEC, NULL, 0x0,
+        { "Length", "usb.setup.length", FT_UINT16, BASE_DEC, NULL, 0x0,
                 "", HFILL }},
                 
         { &hf_usb_data,