Ethereal-dev: [Ethereal-dev] giop - small patch
Note: This archive is from the project's previous web site, ethereal.com. This list is no longer active.
From: Frank Singleton <frank.singleton@xxxxxxxxxxxx>
Date: Tue, 03 Jul 2001 14:33:13 -0500
Hi, Small patch to add subtrees for ServiceContextList and IOR , as these structures can be quite large. Improve readability. Twas diff'd against ethereal-2001-07-03 nightly tarball. /Frank.. -- EUS/SV/Z Frank Singleton ASO Americas BSS Office : +1 972 583 3251 ECN 800 33251 Mobile : +1 214 228 0874 Amateur Radio: VK3FCS/KM5WS Email : frank.singleton@xxxxxxxxxxxx Hardware: HP Omnibook 4150 running Redhat Linux 7.1 (2.4.3-12 kernel).
--- ../ethereal-2001-07-03/packet-giop.c Mon Jul 2 21:27:29 2001
+++ ../ethereal-2001-07-03.updated/packet-giop.c Tue Jul 3 13:19:08 2001
@@ -9,7 +9,7 @@
* Frank Singleton <frank.singleton@xxxxxxxxxxxx>
* Trevor Shepherd <eustrsd@xxxxxxxxxxxxxxx>
*
- * $Id: packet-giop.c,v 1.40 2001/07/03 02:27:29 guy Exp $
+ * $Id: packet-giop.c,v 1.3 2001/07/03 18:19:08 frank Exp $
*
* Ethereal - Network traffic analyzer
* By Gerald Combs <gerald@xxxxxxxxxxxx>
@@ -470,6 +470,9 @@
static gint ett_giop_locate_reply = -1;
static gint ett_giop_fragment = -1;
+static gint ett_giop_scl = -1; /* ServiceContextList */
+static gint ett_giop_ior = -1; /* IOR */
+
/* GIOP endianess */
@@ -4197,7 +4200,10 @@
&ett_giop_cancel_request,
&ett_giop_locate_request,
&ett_giop_locate_reply,
- &ett_giop_fragment
+ &ett_giop_fragment,
+ &ett_giop_scl,
+ &ett_giop_ior
+
};
proto_giop = proto_register_protocol("General Inter-ORB Protocol", "GIOP",
"giop");
@@ -4277,17 +4283,28 @@
*/
-void decode_IOR(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, int *offset,
+void decode_IOR(tvbuff_t *tvb, packet_info *pinfo, proto_tree *ptree, int *offset,
guint32 boundary, gboolean stream_is_big_endian) {
guint32 seqlen_p; /* sequence length of profiles */
guint32 u_octet4;
+ proto_tree *tree = NULL; /* IOR tree */
+ proto_item *tf;
+
gchar *repobuf = NULL; /* for repository ID */
guint32 i;
+ /* create a subtree */
+
+ if (ptree) {
+ tf = proto_tree_add_text (ptree, tvb, *offset, tvb_length (tvb), "IOR");
+ tree = proto_item_add_subtree (tf, ett_giop_ior);
+ }
+
+
/* Get type_id == Repository ID */
u_octet4 = get_CDR_string(tvb,&repobuf,offset,stream_is_big_endian,boundary);
@@ -4633,12 +4650,15 @@
-void decode_ServiceContextList(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, int *offset,
+void decode_ServiceContextList(tvbuff_t *tvb, packet_info *pinfo, proto_tree *ptree, int *offset,
gboolean stream_is_be, guint32 boundary) {
guint32 seqlen; /* sequence length */
guint32 seqlen_cd; /* sequence length, context_data */
+ proto_tree *tree = NULL; /* ServiceContext tree */
+ proto_item *tf;
+
guint32 context_id;
gchar *context_data = NULL;
gchar *p_context_data = NULL;
@@ -4647,6 +4667,12 @@
guint32 vscid; /* Vendor Service context id */
guint32 scid;
+ /* create a subtree */
+
+ if (ptree) {
+ tf = proto_tree_add_text (ptree, tvb, *offset, tvb_length (tvb), "ServiceContextList");
+ tree = proto_item_add_subtree (tf, ett_giop_scl);
+ }
/* Get sequence length (number of elements) */
- Follow-Ups:
- Re: [Ethereal-dev] giop - small patch
- From: Guy Harris
- Re: [Ethereal-dev] giop - small patch
- Prev by Date: Re: [Ethereal-dev] small RX patch
- Next by Date: [Ethereal-dev] Hitting a bug in Ethereal 0.8.18
- Previous by thread: Re: [Ethereal-dev] small RX patch
- Next by thread: Re: [Ethereal-dev] giop - small patch
- Index(es):