summaryrefslogtreecommitdiffstats
path: root/epan/dissectors/packet-pktap.c
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-09-19 04:14:53 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-09-19 04:14:53 +0000
commita86c5f7cae7ec9a3398300555a0b644689d946a1 (patch)
tree39fe4b107c71174fd1e8a8ceb9a4d2aa14116248 /epan/dissectors/packet-pktap.c
parentReleasing progress-linux version 4.2.6-1~progress7.99u1. (diff)
downloadwireshark-a86c5f7cae7ec9a3398300555a0b644689d946a1.tar.xz
wireshark-a86c5f7cae7ec9a3398300555a0b644689d946a1.zip
Merging upstream version 4.4.0.
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'epan/dissectors/packet-pktap.c')
-rw-r--r--epan/dissectors/packet-pktap.c58
1 files changed, 29 insertions, 29 deletions
diff --git a/epan/dissectors/packet-pktap.c b/epan/dissectors/packet-pktap.c
index b4dc1885..201b719f 100644
--- a/epan/dissectors/packet-pktap.c
+++ b/epan/dissectors/packet-pktap.c
@@ -43,27 +43,27 @@ void proto_reg_handoff_pktap(void);
#define PKT_REC_PACKET 1 /* a packet follows the header */
/* Protocol */
-static int proto_pktap = -1;
-
-static int hf_pktap_hdrlen = -1;
-static int hf_pktap_rectype = -1;
-static int hf_pktap_dlt = -1;
-static int hf_pktap_ifname = -1;
-static int hf_pktap_flags = -1;
-static int hf_pktap_pfamily = -1;
-static int hf_pktap_llhdrlen = -1;
-static int hf_pktap_lltrlrlen = -1;
-static int hf_pktap_pid = -1;
-static int hf_pktap_cmdname = -1;
-static int hf_pktap_svc_class = -1;
-static int hf_pktap_iftype = -1;
-static int hf_pktap_ifunit = -1;
-static int hf_pktap_epid = -1;
-static int hf_pktap_ecmdname = -1;
-
-static gint ett_pktap = -1;
-
-static expert_field ei_pktap_hdrlen_too_short = EI_INIT;
+static int proto_pktap;
+
+static int hf_pktap_hdrlen;
+static int hf_pktap_rectype;
+static int hf_pktap_dlt;
+static int hf_pktap_ifname;
+static int hf_pktap_flags;
+static int hf_pktap_pfamily;
+static int hf_pktap_llhdrlen;
+static int hf_pktap_lltrlrlen;
+static int hf_pktap_pid;
+static int hf_pktap_cmdname;
+static int hf_pktap_svc_class;
+static int hf_pktap_iftype;
+static int hf_pktap_ifunit;
+static int hf_pktap_epid;
+static int hf_pktap_ecmdname;
+
+static int ett_pktap;
+
+static expert_field ei_pktap_hdrlen_too_short;
static dissector_handle_t pktap_handle;
static capture_dissector_handle_t eth_cap_handle;
@@ -90,18 +90,18 @@ static capture_dissector_handle_t eth_cap_handle;
* We should do that here.
*/
-static gboolean
-capture_pktap(const guchar *pd, int offset _U_, int len, capture_packet_info_t *cpinfo, const union wtap_pseudo_header *pseudo_header _U_)
+static bool
+capture_pktap(const unsigned char *pd, int offset _U_, int len, capture_packet_info_t *cpinfo, const union wtap_pseudo_header *pseudo_header _U_)
{
- guint32 hdrlen, rectype, dlt;
+ uint32_t hdrlen, rectype, dlt;
hdrlen = pletoh32(pd);
if (hdrlen < MIN_PKTAP_HDR_LEN || !BYTES_ARE_IN_FRAME(0, len, hdrlen))
- return FALSE;
+ return false;
rectype = pletoh32(pd+4);
if (rectype != PKT_REC_PACKET)
- return FALSE;
+ return false;
dlt = pletoh32(pd+4);
@@ -113,7 +113,7 @@ capture_pktap(const guchar *pd, int offset _U_, int len, capture_packet_info_t *
}
- return FALSE;
+ return false;
}
static int
@@ -123,7 +123,7 @@ dissect_pktap(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void* data _U
proto_item *ti = NULL;
tvbuff_t *next_tvb;
int offset = 0;
- guint32 pkt_len, rectype, dlt;
+ uint32_t pkt_len, rectype, dlt;
col_set_str(pinfo->cinfo, COL_PROTOCOL, "PKTAP");
col_clear(pinfo->cinfo, COL_INFO);
@@ -248,7 +248,7 @@ proto_register_pktap(void)
FT_STRINGZ, BASE_NONE, NULL, 0x0, NULL, HFILL } },
};
- static gint *ett[] = {
+ static int *ett[] = {
&ett_pktap,
};