aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--plugins/ethercat/packet-ethercat-frame.c4
-rw-r--r--plugins/ethercat/packet-ethercat-frame.h2
2 files changed, 3 insertions, 3 deletions
diff --git a/plugins/ethercat/packet-ethercat-frame.c b/plugins/ethercat/packet-ethercat-frame.c
index 74b36741f5..18e677563c 100644
--- a/plugins/ethercat/packet-ethercat-frame.c
+++ b/plugins/ethercat/packet-ethercat-frame.c
@@ -103,12 +103,12 @@ static void dissect_ethercat_frame(tvbuff_t *tvb, packet_info *pinfo, proto_tree
handle the rest of the PDU. */
next_tvb = tvb_new_subset (tvb, offset, -1, -1);
- if (!dissector_try_port (ethercat_frame_dissector_table, hdr.protocol,
+ if (!dissector_try_port (ethercat_frame_dissector_table, hdr.v.protocol,
next_tvb, pinfo, tree))
{
if (check_col (pinfo->cinfo, COL_PROTOCOL))
{
- col_add_fstr (pinfo->cinfo, COL_PROTOCOL, "0x%04x", hdr.protocol);
+ col_add_fstr (pinfo->cinfo, COL_PROTOCOL, "0x%04x", hdr.v.protocol);
}
/* No sub dissector wanted to handle this payload, decode it as general
data instead. */
diff --git a/plugins/ethercat/packet-ethercat-frame.h b/plugins/ethercat/packet-ethercat-frame.h
index 1e4346e745..19449a1229 100644
--- a/plugins/ethercat/packet-ethercat-frame.h
+++ b/plugins/ethercat/packet-ethercat-frame.h
@@ -33,7 +33,7 @@ typedef union _EtherCATFrameParser
guint16 length : 11;
guint16 reserved : 1;
guint16 protocol : 4;
- };
+ } v;
guint16 hdr;
} EtherCATFrameParserHDR;
typedef EtherCATFrameParserHDR *PEtherCATFrameParserHDR;