diff options
author | Anders Broman <anders.broman@ericsson.com> | 2009-11-19 21:44:28 +0000 |
---|---|---|
committer | Anders Broman <anders.broman@ericsson.com> | 2009-11-19 21:44:28 +0000 |
commit | b1f6df534a6308095bdd0e22e464061a72251cb6 (patch) | |
tree | edd231830c450ba1abe6c7752912f91c7c57f8c4 /asn1/ansi_map/packet-ansi_map-template.c | |
parent | 6602c02f68ee8c7af75e998c7d52f8545c5c8725 (diff) |
From Michael Lum:
The attached patch calls the tap to allow the number
of each type of message to be counted.
The patch does not fix the "size"/number of octets
column that is all zeroes.
https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=4253
svn path=/trunk/; revision=31027
Diffstat (limited to 'asn1/ansi_map/packet-ansi_map-template.c')
-rw-r--r-- | asn1/ansi_map/packet-ansi_map-template.c | 47 |
1 files changed, 45 insertions, 2 deletions
diff --git a/asn1/ansi_map/packet-ansi_map-template.c b/asn1/ansi_map/packet-ansi_map-template.c index 2cc59c0e0f..1985683d5d 100644 --- a/asn1/ansi_map/packet-ansi_map-template.c +++ b/asn1/ansi_map/packet-ansi_map-template.c @@ -3677,7 +3677,20 @@ dissect_ansi_map_win_trigger_list(tvbuff_t *tvb, packet_info *pinfo _U_, proto_t static int dissect_invokeData(proto_tree *tree, tvbuff_t *tvb, int offset, asn1_ctx_t *actx) { + static gboolean opCodeKnown = TRUE; + static ansi_map_tap_rec_t tap_rec[16]; + static ansi_map_tap_rec_t *tap_p; + static int tap_current=0; + /* + * set tap record pointer + */ + tap_current++; + if (tap_current == array_length(tap_rec)) + { + tap_current = 0; + } + tap_p = &tap_rec[tap_current]; switch(OperationCode){ case 1: /*Handoff Measurement Request*/ @@ -4030,14 +4043,36 @@ static int dissect_invokeData(proto_tree *tree, tvbuff_t *tvb, int offset, asn1_ break; default: proto_tree_add_text(tree, tvb, offset, -1, "Unknown invokeData blob"); + opCodeKnown = FALSE; break; } - return offset; + if (opCodeKnown) + { + tap_p->message_type = OperationCode; + tap_p->size = 0; /* should be number of octets in message */ + + tap_queue_packet(ansi_map_tap, g_pinfo, tap_p); + } + return offset; } static int dissect_returnData(proto_tree *tree, tvbuff_t *tvb, int offset, asn1_ctx_t *actx) { + static gboolean opCodeKnown = TRUE; + static ansi_map_tap_rec_t tap_rec[16]; + static ansi_map_tap_rec_t *tap_p; + static int tap_current=0; + + /* + * set tap record pointer + */ + tap_current++; + if (tap_current == array_length(tap_rec)) + { + tap_current = 0; + } + tap_p = &tap_rec[tap_current]; switch(OperationCode){ case 1: /*Handoff Measurement Request*/ @@ -4271,11 +4306,19 @@ static int dissect_returnData(proto_tree *tree, tvbuff_t *tvb, int offset, asn1_ break; default: proto_tree_add_text(tree, tvb, offset, -1, "Unknown invokeData blob"); + opCodeKnown = FALSE; break; } - return offset; + if (opCodeKnown) + { + tap_p->message_type = OperationCode; + tap_p->size = 0; /* should be number of octets in message */ + + tap_queue_packet(ansi_map_tap, g_pinfo, tap_p); + } + return offset; } static int |