aboutsummaryrefslogtreecommitdiffstats
path: root/epan/dissectors/packet-bmc.c
diff options
context:
space:
mode:
authorAnders Broman <anders.broman@ericsson.com>2012-01-26 19:51:48 +0000
committerAnders Broman <anders.broman@ericsson.com>2012-01-26 19:51:48 +0000
commite1d434ee6a56f86ad9e79e2f127382e3bc4409e6 (patch)
tree60dfbfa55e0b364d2caae8193486767a61fe8baf /epan/dissectors/packet-bmc.c
parent6981aa2c2a465247d0b418d5d6c42325b5a595ad (diff)
From Mike Morrin:
Add dissectors for GSM and UMTS Cell Broadcast protocols. ( - the patch for gsmtap ) https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=6770 svn path=/trunk/; revision=40735
Diffstat (limited to 'epan/dissectors/packet-bmc.c')
-rw-r--r--epan/dissectors/packet-bmc.c16
1 files changed, 11 insertions, 5 deletions
diff --git a/epan/dissectors/packet-bmc.c b/epan/dissectors/packet-bmc.c
index bcc704abe3..af18efb19c 100644
--- a/epan/dissectors/packet-bmc.c
+++ b/epan/dissectors/packet-bmc.c
@@ -32,6 +32,10 @@
#include <epan/bitswap.h>
#include <epan/packet.h>
+#include <epan/asn1.h> /* needed for packet-gsm_map.h */
+
+#include "packet-cell_broadcast.h"
+#include "packet-gsm_map.h"
static int dissect_bmc_cbs_message(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree);
static int dissect_bmc_schedule_message(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree);
@@ -138,19 +142,21 @@ dissect_bmc(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
static int
dissect_bmc_cbs_message(tvbuff_t *tvb, packet_info *pinfo _U_, proto_tree *tree)
{
+ tvbuff_t *cell_broadcast_tvb;
gint offset=1;
- proto_tree_add_item(tree, hf_bmc_message_id, tvb, offset, 2, ENC_BIG_ENDIAN);
+ dissect_cbs_message_identifier(tvb, tree, offset);
offset += 2;
- proto_tree_add_item(tree, hf_bmc_serial_number, tvb, offset, 2, ENC_BIG_ENDIAN);
+ dissect_cbs_serial_number(tvb, tree, offset);
offset += 2;
- proto_tree_add_item(tree, hf_bmc_data_coding_scheme, tvb, offset, 1, ENC_BIG_ENDIAN);
+ dissect_cbs_data_coding_scheme(tvb, pinfo, tree, offset);
offset += 1;
- proto_tree_add_item(tree, hf_bmc_cb_data, tvb, offset, tvb_length_remaining(tvb,offset), ENC_NA);
- offset = tvb_length(tvb);
+ cell_broadcast_tvb = tvb_new_subset(tvb, offset, -1, -1);
+ dissect_umts_cell_broadcast_message(cell_broadcast_tvb, pinfo, tree);
+ offset = tvb_length(cell_broadcast_tvb);
return offset;
}