diff options
author | 2016-10-19 13:53:21 -0700 | |
---|---|---|
committer | 2016-10-19 13:53:21 -0700 | |
commit | 59f347e125182a273f32907f28fa09a264763ffc (patch) | |
tree | e8f6098abdcf2f741e4833c875d71f4ff6257360 /src/core/ext/lb_policy/round_robin | |
parent | 583eb9b96f83f8e443ee530d0cc8df9c233a2de9 (diff) | |
parent | ee167049f5834950b857d4d24aafd7f0738361fb (diff) |
Merge branch 'master' into uv_core_transport
Diffstat (limited to 'src/core/ext/lb_policy/round_robin')
-rw-r--r-- | src/core/ext/lb_policy/round_robin/round_robin.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/core/ext/lb_policy/round_robin/round_robin.c b/src/core/ext/lb_policy/round_robin/round_robin.c index 3cd14b8f4f..3a9250fd61 100644 --- a/src/core/ext/lb_policy/round_robin/round_robin.c +++ b/src/core/ext/lb_policy/round_robin/round_robin.c @@ -396,7 +396,6 @@ static int rr_pick(grpc_exec_ctx *exec_ctx, grpc_lb_policy *pol, gpr_mu_lock(&p->mu); if ((selected = peek_next_connected_locked(p))) { /* readily available, report right away */ - gpr_mu_unlock(&p->mu); *target = grpc_subchannel_get_connected_subchannel(selected->subchannel); if (user_data != NULL) { @@ -409,6 +408,7 @@ static int rr_pick(grpc_exec_ctx *exec_ctx, grpc_lb_policy *pol, } /* only advance the last picked pointer if the selection was used */ advance_last_picked_locked(p); + gpr_mu_unlock(&p->mu); return 1; } else { /* no pick currently available. Save for later in list of pending picks */ |