summaryrefslogtreecommitdiff
path: root/plugins/ethercat/packet-ethercat-frame.h
diff options
context:
space:
mode:
authorAnders Broman <anders.broman@ericsson.com>2007-10-15 18:39:58 +0000
committerAnders Broman <anders.broman@ericsson.com>2007-10-15 18:39:58 +0000
commit721796617d2f4353eef25b1e08945951917c4e65 (patch)
treecf6c57fe8c03dc5f58ca67697fef27d91d116380 /plugins/ethercat/packet-ethercat-frame.h
parent4644ce72634f90e866519faf0a06aca2f7adee12 (diff)
downloadwireshark-721796617d2f4353eef25b1e08945951917c4e65.tar.gz
From Peter Johansson:
addressing the compilation problems svn path=/trunk/; revision=23188
Diffstat (limited to 'plugins/ethercat/packet-ethercat-frame.h')
-rw-r--r--plugins/ethercat/packet-ethercat-frame.h17
1 files changed, 9 insertions, 8 deletions
diff --git a/plugins/ethercat/packet-ethercat-frame.h b/plugins/ethercat/packet-ethercat-frame.h
index b43bc66329..1e4346e745 100644
--- a/plugins/ethercat/packet-ethercat-frame.h
+++ b/plugins/ethercat/packet-ethercat-frame.h
@@ -25,18 +25,19 @@
#ifndef _PACKET_ETHERCAT_FRAME_H
#define _PACKET_ETHERCAT_FRAME_H
-/* Ensure the same data layout for all platforms */
-#pragma pack(push, 1)
-
/* structure for decoding the header -----------------------------------------*/
-typedef struct _EtherCATFrameParser
+typedef union _EtherCATFrameParser
{
- guint16 length : 11;
- guint16 reserved : 1;
- guint16 protocol : 4;
+ struct
+ {
+ guint16 length : 11;
+ guint16 reserved : 1;
+ guint16 protocol : 4;
+ };
+ guint16 hdr;
} EtherCATFrameParserHDR;
typedef EtherCATFrameParserHDR *PEtherCATFrameParserHDR;
-#pragma pack(pop)
+#define EtherCATFrameParserHDR_Len sizeof(EtherCATFrameParserHDR)
#endif