aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/core/ext/filters/client_channel/subchannel.cc
diff options
context:
space:
mode:
authorGravatar ncteisen <ncteisen@gmail.com>2018-07-16 09:16:54 -0700
committerGravatar ncteisen <ncteisen@gmail.com>2018-07-16 09:16:54 -0700
commitd6c5c3c3e57fe4e2b687a23f29fd2ffab98ec10a (patch)
tree7feacd4cbe8f454cee08e413f729fe2a5a9f9b98 /src/core/ext/filters/client_channel/subchannel.cc
parent1f325781bced4f6311462cf4e7682aa99ea34d0b (diff)
Fix ASAN
Diffstat (limited to 'src/core/ext/filters/client_channel/subchannel.cc')
-rw-r--r--src/core/ext/filters/client_channel/subchannel.cc3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/core/ext/filters/client_channel/subchannel.cc b/src/core/ext/filters/client_channel/subchannel.cc
index 0e349da3e2..86026b70a5 100644
--- a/src/core/ext/filters/client_channel/subchannel.cc
+++ b/src/core/ext/filters/client_channel/subchannel.cc
@@ -181,6 +181,9 @@ static void connection_destroy(void* arg, grpc_error* error) {
static void subchannel_destroy(void* arg, grpc_error* error) {
grpc_subchannel* c = static_cast<grpc_subchannel*>(arg);
+ if (c->channelz_subchannel != nullptr) {
+ c->channelz_subchannel.reset();
+ }
gpr_free((void*)c->filters);
grpc_channel_args_destroy(c->args);
grpc_connectivity_state_destroy(&c->state_tracker);