Merge pull request #25296 from apolcyn/remove_unused_pss

Remove unnecessary internal pollset set in c-ares DNS resolver
pull/25262/head
apolcyn 4 years ago committed by GitHub
commit bbdee45274
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 7
      src/core/ext/filters/client_channel/resolver/dns/c_ares/dns_resolver_ares.cc

@ -135,7 +135,7 @@ AresDnsResolver::AresDnsResolver(ResolverArgs args)
channel_args_(grpc_channel_args_copy(args.args)),
work_serializer_(std::move(args.work_serializer)),
result_handler_(std::move(args.result_handler)),
interested_parties_(grpc_pollset_set_create()),
interested_parties_(args.pollset_set),
request_service_config_(!grpc_channel_args_find_bool(
channel_args_, GRPC_ARG_SERVICE_CONFIG_DISABLE_RESOLUTION, true)),
enable_srv_queries_(grpc_channel_args_find_bool(
@ -157,15 +157,10 @@ AresDnsResolver::AresDnsResolver(ResolverArgs args)
GRPC_CLOSURE_INIT(&on_next_resolution_, OnNextResolution, this,
grpc_schedule_on_exec_ctx);
GRPC_CLOSURE_INIT(&on_resolved_, OnResolved, this, grpc_schedule_on_exec_ctx);
// Polling linkage.
if (args.pollset_set != nullptr) {
grpc_pollset_set_add_pollset_set(interested_parties_, args.pollset_set);
}
}
AresDnsResolver::~AresDnsResolver() {
GRPC_CARES_TRACE_LOG("resolver:%p destroying AresDnsResolver", this);
grpc_pollset_set_destroy(interested_parties_);
grpc_channel_args_destroy(channel_args_);
}

Loading…
Cancel
Save