fix no_proxy_str memory leak

pull/14137/head
Jan Tattermusch 7 years ago
parent 20e7074e41
commit 81b608a0b8
  1. 2
      src/core/ext/filters/client_channel/http_proxy.cc

@ -115,6 +115,7 @@ static bool proxy_mapper_map_name(grpc_proxy_mapper* mapper,
"unable to split host and port, not checking no_proxy list for " "unable to split host and port, not checking no_proxy list for "
"host '%s'", "host '%s'",
server_uri); server_uri);
gpr_free(no_proxy_str);
} else { } else {
size_t uri_len = strlen(server_host); size_t uri_len = strlen(server_host);
char** no_proxy_hosts; char** no_proxy_hosts;
@ -139,6 +140,7 @@ static bool proxy_mapper_map_name(grpc_proxy_mapper* mapper,
gpr_free(no_proxy_hosts); gpr_free(no_proxy_hosts);
gpr_free(server_host); gpr_free(server_host);
gpr_free(server_port); gpr_free(server_port);
gpr_free(no_proxy_str);
if (!use_proxy) goto no_use_proxy; if (!use_proxy) goto no_use_proxy;
} }
} }

Loading…
Cancel
Save