aboutsummaryrefslogtreecommitdiffstats
path: root/epan/dissectors/packet-x224.c
diff options
context:
space:
mode:
authorRonnie Sahlberg <ronnie_sahlberg@ozemail.com.au>2007-10-29 11:32:07 +0000
committerRonnie Sahlberg <ronnie_sahlberg@ozemail.com.au>2007-10-29 11:32:07 +0000
commiteca5a7d7d410554825e972c28c7be7732b32e9d4 (patch)
tree7f28c6d5d782d1eece3e8d1ccb64197cabe878bb /epan/dissectors/packet-x224.c
parentbf43e715215b9120b99b26bba7385defbc207bda (diff)
add a asn2wrs generated T.125 MCP dissector
This dissects the initial Connect-Initial and Connect-confirm pdus of setting up t.125 The dissector needs to be enhanced to also decode the data payload so that it can decode any furhter packets on the connection after these two initial handshake packets svn path=/trunk/; revision=23307
Diffstat (limited to 'epan/dissectors/packet-x224.c')
-rw-r--r--epan/dissectors/packet-x224.c14
1 files changed, 12 insertions, 2 deletions
diff --git a/epan/dissectors/packet-x224.c b/epan/dissectors/packet-x224.c
index a8c06b89b2..a2b066a7eb 100644
--- a/epan/dissectors/packet-x224.c
+++ b/epan/dissectors/packet-x224.c
@@ -53,6 +53,10 @@ static int hf_x224_eot = -1;
static gint ett_x224 = -1;
+/* find the dissector for T.125 */
+static dissector_handle_t t125_handle;
+
+
typedef struct _x224_conv_info_t {
guint8 class;
} x224_conv_info_t;
@@ -135,9 +139,10 @@ dissect_x224_cc(packet_info *pinfo _U_, proto_tree *tree, tvbuff_t *tvb, int off
}
static int
-dissect_x224_dt(packet_info *pinfo _U_, proto_tree *tree, tvbuff_t *tvb, int offset, x224_conv_info_t *x224_info)
+dissect_x224_dt(packet_info *pinfo _U_, proto_tree *tree, tvbuff_t *tvb, int offset, x224_conv_info_t *x224_info, proto_tree *parent_tree)
{
proto_item *item = NULL;
+ tvbuff_t *next_tvb;
switch (x224_info->class >>4) {
case 2:
@@ -158,6 +163,10 @@ dissect_x224_dt(packet_info *pinfo _U_, proto_tree *tree, tvbuff_t *tvb, int off
proto_tree_add_item(tree, hf_x224_nr, tvb, offset, 1, FALSE);
offset+=1;
+
+ next_tvb = tvb_new_subset(tvb, offset, -1, -1);
+ call_dissector(t125_handle, next_tvb, pinfo, parent_tree);
+
return offset;
}
@@ -248,7 +257,7 @@ dissect_x224(tvbuff_t *tvb, packet_info *pinfo, proto_tree *parent_tree)
/* XXX not implemented yet */
break;
case X224_CODE_DT:
- offset = dissect_x224_dt(pinfo, tree, tvb, offset, x224_info);
+ offset = dissect_x224_dt(pinfo, tree, tvb, offset, x224_info, parent_tree);
break;
case X224_CODE_ED:
/* XXX not implemented yet */
@@ -318,4 +327,5 @@ proto_register_x224(void)
void
proto_reg_handoff_x224(void)
{
+ t125_handle = find_dissector("t125");
}