summaryrefslogtreecommitdiffstats
path: root/epan/dissectors/packet-rmi.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-rmi.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-rmi.c')
-rw-r--r--epan/dissectors/packet-rmi.c86
1 files changed, 43 insertions, 43 deletions
diff --git a/epan/dissectors/packet-rmi.c b/epan/dissectors/packet-rmi.c
index 74ebe840..a7c3a935 100644
--- a/epan/dissectors/packet-rmi.c
+++ b/epan/dissectors/packet-rmi.c
@@ -25,37 +25,37 @@ static void
dissect_ser(tvbuff_t *tvb, proto_tree *tree);
static rmi_type
-get_rmi_type(tvbuff_t *tvb, gint offset, int datalen);
+get_rmi_type(tvbuff_t *tvb, int offset, int datalen);
/* Initialize the protocol and registered fields */
-static int proto_rmi = -1;
-static int proto_ser = -1;
-static int hf_rmi_magic = -1;
-static int hf_rmi_version = -1;
-static int hf_rmi_protocol = -1;
-static int hf_rmi_inputmessage = -1;
-static int hf_rmi_outputmessage = -1;
-static int hf_rmi_epid_length = -1;
-static int hf_rmi_epid_hostname = -1;
-static int hf_rmi_epid_port = -1;
-static int hf_rmi_serialization_data = -1;
-static int hf_rmi_unique_identifier = -1;
-
-static int hf_ser_magic = -1;
-static int hf_ser_version = -1;
+static int proto_rmi;
+static int proto_ser;
+static int hf_rmi_magic;
+static int hf_rmi_version;
+static int hf_rmi_protocol;
+static int hf_rmi_inputmessage;
+static int hf_rmi_outputmessage;
+static int hf_rmi_epid_length;
+static int hf_rmi_epid_hostname;
+static int hf_rmi_epid_port;
+static int hf_rmi_serialization_data;
+static int hf_rmi_unique_identifier;
+
+static int hf_ser_magic;
+static int hf_ser_version;
/* Initialize the subtree pointers */
-static gint ett_rmi = -1;
-static gint ett_rmi_magic = -1;
-static gint ett_rmi_version = -1;
-static gint ett_rmi_inputmessage = -1;
-static gint ett_rmi_outputmessage = -1;
-static gint ett_rmi_epid_length = -1;
-static gint ett_rmi_epid_hostname = -1;
-static gint ett_rmi_epid_port = -1;
-static gint ett_rmi_endpoint_identifier = -1;
-
-static gint ett_ser = -1;
+static int ett_rmi;
+static int ett_rmi_magic;
+static int ett_rmi_version;
+static int ett_rmi_inputmessage;
+static int ett_rmi_outputmessage;
+static int ett_rmi_epid_length;
+static int ett_rmi_epid_hostname;
+static int ett_rmi_epid_port;
+static int ett_rmi_endpoint_identifier;
+
+static int ett_ser;
/*
* See
@@ -101,19 +101,19 @@ dissect_rmi(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void* data _U_)
tvbuff_t *next_tvb;
- gint offset = 0;
- gint next_offset;
+ int offset = 0;
+ int next_offset;
int datalen;
- guint16 version, len, port;
- guint8 message, proto;
+ uint16_t version, len, port;
+ uint8_t message, proto;
rmi_type rmitype;
/* Make entries in Protocol column and Info column on summary display */
col_set_str(pinfo->cinfo, COL_PROTOCOL, "RMI");
- datalen = tvb_find_line_end(tvb, offset, -1, &next_offset, FALSE);
+ datalen = tvb_find_line_end(tvb, offset, -1, &next_offset, false);
rmitype = get_rmi_type(tvb, offset, datalen);
@@ -123,13 +123,13 @@ dissect_rmi(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void* data _U_)
col_add_fstr(pinfo->cinfo, COL_INFO,
"JRMI, Version: %d, ", version);
- proto = tvb_get_guint8(tvb, 6);
+ proto = tvb_get_uint8(tvb, 6);
col_append_str(pinfo->cinfo, COL_INFO,
val_to_str_const(proto, rmi_protocol_str,
"Unknown protocol"));
break;
case RMI_OUTPUTMESSAGE:
- message = tvb_get_guint8(tvb,0);
+ message = tvb_get_uint8(tvb,0);
col_set_str(pinfo->cinfo, COL_INFO,
"JRMI, ");
col_append_str(pinfo->cinfo, COL_INFO,
@@ -137,7 +137,7 @@ dissect_rmi(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void* data _U_)
"Unknown message"));
break;
case RMI_INPUTSTREAM:
- message = tvb_get_guint8(tvb,0);
+ message = tvb_get_uint8(tvb,0);
col_set_str(pinfo->cinfo, COL_INFO,
"JRMI, ");
col_append_str(pinfo->cinfo, COL_INFO,
@@ -168,7 +168,7 @@ dissect_rmi(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void* data _U_)
tvb, offset + 6, 1, ENC_BIG_ENDIAN);
break;
case RMI_INPUTSTREAM:
- message = tvb_get_guint8(tvb, 0);
+ message = tvb_get_uint8(tvb, 0);
proto_tree_add_uint(rmi_tree, hf_rmi_inputmessage,
tvb, offset, 1, message);
if(message == RMI_INPUTSTREAM_MESSAGE_ACK) {
@@ -198,7 +198,7 @@ dissect_rmi(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void* data _U_)
}
break;
case RMI_OUTPUTMESSAGE:
- message = tvb_get_guint8(tvb, 0);
+ message = tvb_get_uint8(tvb, 0);
proto_tree_add_uint(rmi_tree, hf_rmi_outputmessage,
tvb, offset, 1, message);
if(message == RMI_OUTPUTSTREAM_MESSAGE_CALL) {
@@ -228,7 +228,7 @@ dissect_ser(tvbuff_t *tvb, proto_tree *tree)
proto_item *ti;
proto_tree *ser_tree;
- gint offset;
+ int offset;
offset = 0;
@@ -244,10 +244,10 @@ dissect_ser(tvbuff_t *tvb, proto_tree *tree)
}
static rmi_type
-get_rmi_type(tvbuff_t *tvb, gint offset, int datalen)
+get_rmi_type(tvbuff_t *tvb, int offset, int datalen)
{
- guint16 ser_magic;
- guchar data[4];
+ uint16_t ser_magic;
+ unsigned char data[4];
tvb_memcpy(tvb, data, offset, (datalen > 4) ? 4 : datalen);
@@ -316,7 +316,7 @@ proto_register_rmi(void)
{ &hf_rmi_epid_port,
{ "Port", "rmi.endpoint_id.port",
FT_UINT16, BASE_DEC, NULL, 0x0,
- "RMI Endpointindentifier Port", HFILL }},
+ "RMI Endpointidentifier Port", HFILL }},
{ &hf_rmi_serialization_data,
{ "Serialization Data", "rmi.serialization_data",
FT_BYTES, BASE_NONE, NULL, 0x0,
@@ -336,7 +336,7 @@ proto_register_rmi(void)
"Java Serialization Version", HFILL }},
};
- static gint *ett[] = {
+ static int *ett[] = {
&ett_rmi,
&ett_rmi_magic,
&ett_rmi_version,