diff options
author | Guy Harris <guy@alum.mit.edu> | 2005-01-01 02:57:02 +0000 |
---|---|---|
committer | Guy Harris <guy@alum.mit.edu> | 2005-01-01 02:57:02 +0000 |
commit | 71217a80071adae12b53253e3025b2220e6c89f5 (patch) | |
tree | 0e6002853a3a04b81db3f093f0a09459ebbccc7e /epan | |
parent | 3f0d0ca5ea5f6034904e4cb03b38b66e7b03e165 (diff) |
As we've made the tap_specific_data field of a tap_packet_t structure a
const pointer (so that we don't get complaints when we make the
tap-specific data argument to "tap_queue_packet()" a const pointer,
allowing dissectors to hand const data to a tap without a complaint), we
should make the tap per-packet function take a const pointer as an
argument as well. Do so.
In some taps, use _U_, or actually use the argument, rather than
sticking in dummy "X = X" assignments to fake use of parameters. (This
means that the tap functions in question no longer have the notion that
they act on a particular static structure wired in.)
svn path=/trunk/; revision=12910
Diffstat (limited to 'epan')
-rw-r--r-- | epan/dissectors/packet-bootp.c | 2 | ||||
-rw-r--r-- | epan/dissectors/packet-smb-sidsnooping.c | 6 | ||||
-rw-r--r-- | epan/tap.h | 2 |
3 files changed, 5 insertions, 5 deletions
diff --git a/epan/dissectors/packet-bootp.c b/epan/dissectors/packet-bootp.c index 58bb88187e..5b2cea898d 100644 --- a/epan/dissectors/packet-bootp.c +++ b/epan/dissectors/packet-bootp.c @@ -2894,7 +2894,7 @@ dissect_bootp(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree) if (tree) proto_tree_add_boolean_hidden(bp_tree, hf_bootp_dhcp, tvb, 0, 0, 1); - tap_queue_packet( bootp_dhcp_tap, pinfo, (gpointer) dhcp_type); + tap_queue_packet( bootp_dhcp_tap, pinfo, dhcp_type); } /* diff --git a/epan/dissectors/packet-smb-sidsnooping.c b/epan/dissectors/packet-smb-sidsnooping.c index bf3929c109..c706c76239 100644 --- a/epan/dissectors/packet-smb-sidsnooping.c +++ b/epan/dissectors/packet-smb-sidsnooping.c @@ -105,9 +105,9 @@ add_sid_name_mapping(char *sid, char *name) * level 1 : user displayinfo 1 */ static int -samr_query_dispinfo(void *dummy _U_, packet_info *pinfo, epan_dissect_t *edt, void *pri) +samr_query_dispinfo(void *dummy _U_, packet_info *pinfo, epan_dissect_t *edt, const void *pri) { - dcerpc_info *ri=pri; + const dcerpc_info *ri=pri; void *old_ctx=NULL; char *pol_name; char *sid; @@ -227,7 +227,7 @@ samr_query_dispinfo(void *dummy _U_, packet_info *pinfo, epan_dissect_t *edt, vo * level 12 : DNS_DOMAIN_INFO lsa.domain_sid -> lsa.domain */ static int -lsa_policy_information(void *dummy _U_, packet_info *pinfo _U_, epan_dissect_t *edt, void *pri _U_) +lsa_policy_information(void *dummy _U_, packet_info *pinfo _U_, epan_dissect_t *edt, const void *pri _U_) { GPtrArray *gp; field_info *fi; diff --git a/epan/tap.h b/epan/tap.h index 4ecb1fb91d..e8b27f2e9d 100644 --- a/epan/tap.h +++ b/epan/tap.h @@ -33,7 +33,7 @@ ETH_VAR_IMPORT int num_tap_filters; typedef void (*tap_reset_cb)(void *tapdata); -typedef int (*tap_packet_cb)(void *tapdata, packet_info *pinfo, epan_dissect_t *edt, void *data); +typedef int (*tap_packet_cb)(void *tapdata, packet_info *pinfo, epan_dissect_t *edt, const void *data); typedef void (*tap_draw_cb)(void *tapdata); |