aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorGravatar apolcyn <apolcyn@google.com>2017-10-04 13:51:12 -0700
committerGravatar GitHub <noreply@github.com>2017-10-04 13:51:12 -0700
commit3137faac5cc1bcff58fa2729bb57489f1aa12cef (patch)
treeb8d162006296cb8c5e1afdc87ad7e126cb4a3da4
parent8e2e9a6d91b45069651f5331dee9bff757126be8 (diff)
parentd05f2f77d297e8d24480f87bbab9ee73cf014f7b (diff)
Merge pull request #12803 from murgatroid99/backport_uv_refcount_fix
Backport #12733
-rw-r--r--src/core/lib/iomgr/tcp_client_uv.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/core/lib/iomgr/tcp_client_uv.c b/src/core/lib/iomgr/tcp_client_uv.c
index 786c456b73..0d9e7ed5f6 100644
--- a/src/core/lib/iomgr/tcp_client_uv.c
+++ b/src/core/lib/iomgr/tcp_client_uv.c
@@ -145,7 +145,7 @@ static void tcp_client_connect_impl(grpc_exec_ctx *exec_ctx,
connect->resource_quota = resource_quota;
uv_tcp_init(uv_default_loop(), connect->tcp_handle);
connect->connect_req.data = connect;
- connect->refs = 1;
+ connect->refs = 2; // One for the connect operation, one for the timer.
if (GRPC_TRACER_ON(grpc_tcp_trace)) {
gpr_log(GPR_DEBUG, "CLIENT_CONNECT: %s: asynchronously connecting",