diff options
author | Michael Mann <mmann78@netscape.net> | 2017-10-29 10:12:59 -0400 |
---|---|---|
committer | Michael Mann <mmann78@netscape.net> | 2017-10-29 16:53:57 +0000 |
commit | abfb6441177961fbdfa9648fdd2c40ef0ef3cefd (patch) | |
tree | dc5d1b438a052e73ec243d2f10e772e39fec3894 /epan/dissectors/asn1/snmp | |
parent | 1bc6d4e96573f89ecdd719cb3cac92754b91f52c (diff) |
Add conversation endpoint type
For the moment this mirrors the port_type enumeration (PT_XXX), but the
intent is to move away from using "port types", eliminating most (if not
all)
Added conversation_pt_to_endpoint_type() so that conversations deal with the
correct enumeration. This is for dissector that use pinfo->ptype as input
to conversation APIs. Explicit use of port types are converted to using
ENDPOINT_XXX type.
Change-Id: Ia0bf553a3943b702c921f185407e03ce93ebf0ef
Reviewed-on: https://code.wireshark.org/review/24166
Petri-Dish: Michael Mann <mmann78@netscape.net>
Tested-by: Petri Dish Buildbot
Reviewed-by: Michael Mann <mmann78@netscape.net>
Diffstat (limited to 'epan/dissectors/asn1/snmp')
-rw-r--r-- | epan/dissectors/asn1/snmp/packet-snmp-template.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/epan/dissectors/asn1/snmp/packet-snmp-template.c b/epan/dissectors/asn1/snmp/packet-snmp-template.c index 79b433320d..1a8b745cdf 100644 --- a/epan/dissectors/asn1/snmp/packet-snmp-template.c +++ b/epan/dissectors/asn1/snmp/packet-snmp-template.c @@ -2033,10 +2033,10 @@ dissect_snmp(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void *data _U_ * wildcarded, and give it the SNMP dissector as a dissector. */ if (pinfo->destport == UDP_PORT_SNMP) { - conversation = find_conversation(pinfo->num, &pinfo->src, &pinfo->dst, PT_UDP, + conversation = find_conversation(pinfo->num, &pinfo->src, &pinfo->dst, ENDPOINT_UDP, pinfo->srcport, 0, NO_PORT_B); if( (conversation == NULL) || (conversation_get_dissector(conversation, pinfo->num)!=snmp_handle) ) { - conversation = conversation_new(pinfo->num, &pinfo->src, &pinfo->dst, PT_UDP, + conversation = conversation_new(pinfo->num, &pinfo->src, &pinfo->dst, ENDPOINT_UDP, pinfo->srcport, 0, NO_PORT2); conversation_set_dissector(conversation, snmp_handle); } |