From 762bb18b9dd7bc5499db2b715c2854b5f401fab4 Mon Sep 17 00:00:00 2001 From: Alexis La Goutte Date: Wed, 24 Dec 2014 16:16:26 +0100 Subject: RSVP: Conversations / Endpoint: wrong filter when select a RSVP conversations / endpoint (INVALID == a.x.y.z ...) Change-Id: I70f6afd41eefddb42829c3d5f890ea67dcd65537 Reviewed-on: https://code.wireshark.org/review/6037 Reviewed-by: Anders Broman --- epan/dissectors/packet-rsvp.c | 17 ++++++++++++++--- 1 file changed, 14 insertions(+), 3 deletions(-) (limited to 'epan/dissectors') diff --git a/epan/dissectors/packet-rsvp.c b/epan/dissectors/packet-rsvp.c index 66a7a6db81..a18946be9d 100644 --- a/epan/dissectors/packet-rsvp.c +++ b/epan/dissectors/packet-rsvp.c @@ -1907,9 +1907,17 @@ rsvp_init_protocol(void) rsvp_request_hash = g_hash_table_new(rsvp_hash, rsvp_equal); } -static const char* rsvp_conv_get_filter_type(conv_item_t* conv _U_, conv_filter_type_e filter _U_) +static const char* rsvp_conv_get_filter_type(conv_item_t* conv, conv_filter_type_e filter _U_) { - /* XXX - Not sure about this */ + if ((filter == CONV_FT_SRC_ADDRESS) && (conv->src_address.type == AT_IPv4)) + return "ip.src"; + + if ((filter == CONV_FT_DST_ADDRESS) && (conv->dst_address.type == AT_IPv4)) + return "ip.dst"; + + if ((filter == CONV_FT_ANY_ADDRESS) && (conv->src_address.type == AT_IPv4)) + return "ip.addr"; + return CONV_FILTER_INVALID; } @@ -1929,7 +1937,10 @@ rsvp_conversation_packet(void *pct, packet_info *pinfo, epan_dissect_t *edt _U_, static const char* rsvp_host_get_filter_type(hostlist_talker_t* host _U_, conv_filter_type_e filter) { - return rsvp_conv_get_filter_type(NULL, filter); + if ((filter == CONV_FT_ANY_ADDRESS) && (host->myaddress.type == AT_IPv4)) + return "ip.addr"; + + return CONV_FILTER_INVALID; } static hostlist_dissector_info_t rsvp_host_dissector_info = {&rsvp_host_get_filter_type}; -- cgit v1.2.3