diff options
author | Michael Mann <mmann78@netscape.net> | 2013-11-10 16:39:46 +0000 |
---|---|---|
committer | Michael Mann <mmann78@netscape.net> | 2013-11-10 16:39:46 +0000 |
commit | fe52a15217f645f09640529ce5ad1d344cafbed3 (patch) | |
tree | 624a61b433295083642c9284629ba33e79fba403 /epan/dissectors/packet-klm.c | |
parent | 6f6d04e2f9585f603e713198938197821328c1b5 (diff) |
Have rpc_call_info_value be passed through to (sub)dissectors instead of using pinfo->private_data.
This was acheived by adding a void* data parameter to the dissect_function_t typedef in packet-rpc.h (r53213). After converting the pinfo->private_data, I'm not sure if it would be better to change the void* data pointer to be a rpc_call_info_value* explicitly. Not all "dissector functions" use it, but it would certainly save a lot of casting...
svn path=/trunk/; revision=53232
Diffstat (limited to 'epan/dissectors/packet-klm.c')
-rw-r--r-- | epan/dissectors/packet-klm.c | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/epan/dissectors/packet-klm.c b/epan/dissectors/packet-klm.c index 7b977f30d0..e8a1ef5498 100644 --- a/epan/dissectors/packet-klm.c +++ b/epan/dissectors/packet-klm.c @@ -86,7 +86,7 @@ dissect_holder(tvbuff_t *tvb, proto_tree *tree, int offset) } static int -dissect_lock(tvbuff_t *tvb, packet_info* pinfo, proto_tree *tree, int offset) +dissect_lock(tvbuff_t *tvb, packet_info* pinfo, proto_tree *tree, int offset, rpc_call_info_value *civ) { proto_item* lock_item = NULL; proto_tree* lock_tree = NULL; @@ -99,7 +99,7 @@ dissect_lock(tvbuff_t *tvb, packet_info* pinfo, proto_tree *tree, int offset) offset = dissect_rpc_string(tvb, lock_tree, hf_klm_servername, offset, NULL); - offset = dissect_nfs3_fh(tvb, offset, pinfo, lock_tree,"fh", NULL); + offset = dissect_nfs3_fh(tvb, offset, pinfo, lock_tree,"fh", NULL, civ); offset = dissect_rpc_uint32(tvb, lock_tree, hf_klm_pid, offset); @@ -114,9 +114,9 @@ dissect_lock(tvbuff_t *tvb, packet_info* pinfo, proto_tree *tree, int offset) } static int -dissect_klm_unlock_call(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, void* data _U_) +dissect_klm_unlock_call(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, void* data) { - offset = dissect_lock(tvb, pinfo, tree, offset); + offset = dissect_lock(tvb, pinfo, tree, offset, (rpc_call_info_value*)data); return offset; } @@ -132,7 +132,7 @@ dissect_klm_stat_reply(tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_ } static int -dissect_klm_lock_call(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, void* data _U_) +dissect_klm_lock_call(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, void* data) { offset = dissect_rpc_bool( tvb, tree, hf_klm_block, offset); @@ -140,7 +140,7 @@ dissect_klm_lock_call(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree offset = dissect_rpc_bool( tvb, tree, hf_klm_exclusive, offset); - offset = dissect_lock(tvb, pinfo, tree, offset); + offset = dissect_lock(tvb, pinfo, tree, offset, (rpc_call_info_value*)data); return offset; } @@ -163,12 +163,12 @@ dissect_klm_test_reply(tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_ } static int -dissect_klm_test_call(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, void* data _U_) +dissect_klm_test_call(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, void* data) { offset = dissect_rpc_bool( tvb, tree, hf_klm_exclusive, offset); - offset = dissect_lock(tvb, pinfo, tree, offset); + offset = dissect_lock(tvb, pinfo, tree, offset, (rpc_call_info_value*)data); return offset; } |