diff options
author | Anders Broman <anders.broman@ericsson.com> | 2013-03-14 19:01:06 +0000 |
---|---|---|
committer | Anders Broman <anders.broman@ericsson.com> | 2013-03-14 19:01:06 +0000 |
commit | f2266d87f5acbe8c6d12998a032fdc42ea90e9f3 (patch) | |
tree | 707c02c727c9b93d3666b5c9030d6499a85d609c /epan/dissectors/packet-batadv.c | |
parent | ffaf67b6158b6c9235a7fe96d345419c371f65ff (diff) |
[-Wmissing-prototypes]
explicit casts.
svn path=/trunk/; revision=48302
Diffstat (limited to 'epan/dissectors/packet-batadv.c')
-rw-r--r-- | epan/dissectors/packet-batadv.c | 45 |
1 files changed, 23 insertions, 22 deletions
diff --git a/epan/dissectors/packet-batadv.c b/epan/dissectors/packet-batadv.c index f63c2bb60c..8e3cf01b72 100644 --- a/epan/dissectors/packet-batadv.c +++ b/epan/dissectors/packet-batadv.c @@ -519,6 +519,7 @@ static const fragment_items msg_frag_items = { /* forward declaration */ +void proto_register_batadv(void); void proto_reg_handoff_batadv(void); static dissector_handle_t batman_handle; @@ -723,7 +724,7 @@ static int dissect_batadv_batman_v5(tvbuff_t *tvb, int offset, packet_info *pinf tvbuff_t *next_tvb; - batman_packeth = ep_alloc(sizeof(struct batman_packet_v5)); + batman_packeth = (struct batman_packet_v5 *)ep_alloc(sizeof(struct batman_packet_v5)); type = tvb_get_guint8(tvb, offset+0); batman_packeth->version = tvb_get_guint8(tvb, offset+1); @@ -833,7 +834,7 @@ static int dissect_batadv_batman_v7(tvbuff_t *tvb, int offset, packet_info *pinf tvbuff_t *next_tvb; - batman_packeth = ep_alloc(sizeof(struct batman_packet_v7)); + batman_packeth = (struct batman_packet_v7 *)ep_alloc(sizeof(struct batman_packet_v7)); type = tvb_get_guint8(tvb, offset+0); batman_packeth->version = tvb_get_guint8(tvb, offset+1); @@ -934,7 +935,7 @@ static int dissect_batadv_batman_v9(tvbuff_t *tvb, int offset, packet_info *pinf tvbuff_t *next_tvb; - batman_packeth = ep_alloc(sizeof(struct batman_packet_v9)); + batman_packeth = (struct batman_packet_v9 *)ep_alloc(sizeof(struct batman_packet_v9)); type = tvb_get_guint8(tvb, offset+0); batman_packeth->version = tvb_get_guint8(tvb, offset+1); @@ -1044,7 +1045,7 @@ static int dissect_batadv_batman_v10(tvbuff_t *tvb, int offset, packet_info *pin tvbuff_t *next_tvb; - batman_packeth = ep_alloc(sizeof(struct batman_packet_v10)); + batman_packeth = (struct batman_packet_v10 *)ep_alloc(sizeof(struct batman_packet_v10)); type = tvb_get_guint8(tvb, offset+0); batman_packeth->version = tvb_get_guint8(tvb, offset+1); @@ -1154,7 +1155,7 @@ static int dissect_batadv_batman_v11(tvbuff_t *tvb, int offset, packet_info *pin tvbuff_t *next_tvb; - batman_packeth = ep_alloc(sizeof(struct batman_packet_v11)); + batman_packeth = (struct batman_packet_v11 *)ep_alloc(sizeof(struct batman_packet_v11)); type = tvb_get_guint8(tvb, offset+0); batman_packeth->version = tvb_get_guint8(tvb, offset+1); @@ -1257,7 +1258,7 @@ static int dissect_batadv_batman_v14(tvbuff_t *tvb, int offset, packet_info *pin tvbuff_t *next_tvb; gint length_remaining; - batman_packeth = ep_alloc(sizeof(struct batman_packet_v14)); + batman_packeth = (struct batman_packet_v14 *)ep_alloc(sizeof(struct batman_packet_v14)); type = tvb_get_guint8(tvb, offset+0); batman_packeth->version = tvb_get_guint8(tvb, offset+1); @@ -1433,7 +1434,7 @@ static void dissect_batadv_bcast_v6(tvbuff_t *tvb, packet_info *pinfo, proto_tre int offset = 0; proto_tree *batadv_bcast_tree = NULL; - bcast_packeth = ep_alloc(sizeof(struct bcast_packet_v6)); + bcast_packeth = (struct bcast_packet_v6 *)ep_alloc(sizeof(struct bcast_packet_v6)); bcast_packeth->version = tvb_get_guint8(tvb, 1); orig_addr = tvb_get_ptr(tvb, 2, 6); @@ -1497,7 +1498,7 @@ static void dissect_batadv_bcast_v10(tvbuff_t *tvb, packet_info *pinfo, proto_tr int offset = 0; proto_tree *batadv_bcast_tree = NULL; - bcast_packeth = ep_alloc(sizeof(struct bcast_packet_v10)); + bcast_packeth = (struct bcast_packet_v10 *)ep_alloc(sizeof(struct bcast_packet_v10)); bcast_packeth->version = tvb_get_guint8(tvb, 1); orig_addr = tvb_get_ptr(tvb, 2, 6); @@ -1566,7 +1567,7 @@ static void dissect_batadv_bcast_v14(tvbuff_t *tvb, packet_info *pinfo, proto_tr int offset = 0; proto_tree *batadv_bcast_tree = NULL; - bcast_packeth = ep_alloc(sizeof(struct bcast_packet_v14)); + bcast_packeth = (struct bcast_packet_v14 *)ep_alloc(sizeof(struct bcast_packet_v14)); bcast_packeth->version = tvb_get_guint8(tvb, 1); bcast_packeth->ttl = tvb_get_guint8(tvb, 2); @@ -1670,7 +1671,7 @@ static void dissect_batadv_icmp_v6(tvbuff_t *tvb, packet_info *pinfo, proto_tree int offset = 0; proto_tree *batadv_icmp_tree = NULL; - icmp_packeth = ep_alloc(sizeof(struct icmp_packet_v6)); + icmp_packeth = (struct icmp_packet_v6 *)ep_alloc(sizeof(struct icmp_packet_v6)); icmp_packeth->version = tvb_get_guint8(tvb, 1); icmp_packeth->msg_type = tvb_get_guint8(tvb, 2); @@ -1779,7 +1780,7 @@ static void dissect_batadv_icmp_v7(tvbuff_t *tvb, packet_info *pinfo, proto_tree gint length_remaining; int offset = 0; - icmp_packeth = ep_alloc(sizeof(struct icmp_packet_v7)); + icmp_packeth = (struct icmp_packet_v7 *)ep_alloc(sizeof(struct icmp_packet_v7)); icmp_packeth->version = tvb_get_guint8(tvb, 1); icmp_packeth->msg_type = tvb_get_guint8(tvb, 2); @@ -1867,7 +1868,7 @@ static void dissect_batadv_icmp_v14(tvbuff_t *tvb, packet_info *pinfo, proto_tre gint length_remaining; int offset = 0; - icmp_packeth = ep_alloc(sizeof(struct icmp_packet_v14)); + icmp_packeth = (struct icmp_packet_v14 *)ep_alloc(sizeof(struct icmp_packet_v14)); icmp_packeth->version = tvb_get_guint8(tvb, 1); icmp_packeth->ttl = tvb_get_guint8(tvb, 2); @@ -1987,7 +1988,7 @@ static void dissect_batadv_unicast_v6(tvbuff_t *tvb, packet_info *pinfo, proto_t int offset = 0; proto_tree *batadv_unicast_tree = NULL; - unicast_packeth = ep_alloc(sizeof(struct unicast_packet_v6)); + unicast_packeth = (struct unicast_packet_v6 *)ep_alloc(sizeof(struct unicast_packet_v6)); unicast_packeth->version = tvb_get_guint8(tvb, 1); dest_addr = tvb_get_ptr(tvb, 2, 6); @@ -2052,7 +2053,7 @@ static void dissect_batadv_unicast_v14(tvbuff_t *tvb, packet_info *pinfo, proto_ int offset = 0; proto_tree *batadv_unicast_tree = NULL; - unicast_packeth = ep_alloc(sizeof(struct unicast_packet_v14)); + unicast_packeth = (struct unicast_packet_v14 *)ep_alloc(sizeof(struct unicast_packet_v14)); unicast_packeth->version = tvb_get_guint8(tvb, 1); unicast_packeth->ttl = tvb_get_guint8(tvb, 2); @@ -2140,7 +2141,7 @@ static void dissect_batadv_unicast_4addr_v14(tvbuff_t *tvb, packet_info *pinfo, int offset = 0; proto_tree *batadv_unicast_4addr_tree = NULL; - unicast_4addr_packeth = ep_alloc(sizeof(struct unicast_4addr_packet_v14)); + unicast_4addr_packeth = (struct unicast_4addr_packet_v14 *)ep_alloc(sizeof(struct unicast_4addr_packet_v14)); unicast_4addr_packeth->version = tvb_get_guint8(tvb, 1); unicast_4addr_packeth->ttl = tvb_get_guint8(tvb, 2); @@ -2248,7 +2249,7 @@ static void dissect_batadv_unicast_frag_v12(tvbuff_t *tvb, packet_info *pinfo, p int head = 0; gint length_remaining; - unicast_frag_packeth = ep_alloc(sizeof(struct unicast_frag_packet_v12)); + unicast_frag_packeth = (struct unicast_frag_packet_v12 *)ep_alloc(sizeof(struct unicast_frag_packet_v12)); unicast_frag_packeth->version = tvb_get_guint8(tvb, 1); dest_addr = tvb_get_ptr(tvb, 2, 6); @@ -2355,7 +2356,7 @@ static void dissect_batadv_unicast_frag_v14(tvbuff_t *tvb, packet_info *pinfo, p int head = 0; gint length_remaining; - unicast_frag_packeth = ep_alloc(sizeof(struct unicast_frag_packet_v14)); + unicast_frag_packeth = (struct unicast_frag_packet_v14 *)ep_alloc(sizeof(struct unicast_frag_packet_v14)); unicast_frag_packeth->version = tvb_get_guint8(tvb, 1); unicast_frag_packeth->ttl = tvb_get_guint8(tvb, 2); @@ -2498,7 +2499,7 @@ static void dissect_batadv_vis_v6(tvbuff_t *tvb, packet_info *pinfo, proto_tree gint length_remaining; int offset = 0, i; - vis_packeth = ep_alloc(sizeof(struct vis_packet_v6)); + vis_packeth = (struct vis_packet_v6 *)ep_alloc(sizeof(struct vis_packet_v6)); vis_packeth->version = tvb_get_guint8(tvb, 1); vis_packeth->vis_type = tvb_get_guint8(tvb, 2); @@ -2626,7 +2627,7 @@ static void dissect_batadv_vis_v10(tvbuff_t *tvb, packet_info *pinfo, proto_tree gint length_remaining; int offset = 0, i; - vis_packeth = ep_alloc(sizeof(struct vis_packet_v10)); + vis_packeth = (struct vis_packet_v10 *)ep_alloc(sizeof(struct vis_packet_v10)); vis_packeth->version = tvb_get_guint8(tvb, 1); vis_packeth->vis_type = tvb_get_guint8(tvb, 2); @@ -2730,7 +2731,7 @@ static void dissect_batadv_vis_v14(tvbuff_t *tvb, packet_info *pinfo, proto_tree gint length_remaining; int offset = 0, i; - vis_packeth = ep_alloc(sizeof(struct vis_packet_v14)); + vis_packeth = (struct vis_packet_v14 *)ep_alloc(sizeof(struct vis_packet_v14)); vis_packeth->version = tvb_get_guint8(tvb, 1); vis_packeth->ttl = tvb_get_guint8(tvb, 2); @@ -2909,7 +2910,7 @@ static void dissect_batadv_tt_query_v14(tvbuff_t *tvb, packet_info *pinfo _U_, p int offset = 0, i; int tt_type; - tt_query_packeth = ep_alloc(sizeof(struct tt_query_packet_v14)); + tt_query_packeth = (struct tt_query_packet_v14 *)ep_alloc(sizeof(struct tt_query_packet_v14)); tt_query_packeth->version = tvb_get_guint8(tvb, 1); tt_query_packeth->ttl = tvb_get_guint8(tvb, 2); @@ -3085,7 +3086,7 @@ static void dissect_batadv_roam_adv_v14(tvbuff_t *tvb, packet_info *pinfo, proto gint length_remaining; int offset = 0; - roam_adv_packeth = ep_alloc(sizeof(struct roam_adv_packet_v14)); + roam_adv_packeth = (struct roam_adv_packet_v14 *)ep_alloc(sizeof(struct roam_adv_packet_v14)); roam_adv_packeth->version = tvb_get_guint8(tvb, 1); roam_adv_packeth->ttl = tvb_get_guint8(tvb, 2); |