Flush exec_ctx before using pollset_work

reviewable/pr11237/r1
Yuchen Zeng 8 years ago
parent bcb65f0bd5
commit b1f0af8951
  1. 2
      test/core/util/port_server_client.c

@ -108,6 +108,7 @@ void grpc_free_port_using_server(int port) {
&rsp); &rsp);
grpc_resource_quota_unref_internal(&exec_ctx, resource_quota); grpc_resource_quota_unref_internal(&exec_ctx, resource_quota);
gpr_mu_lock(pr.mu); gpr_mu_lock(pr.mu);
grpc_exec_ctx_flush(&exec_ctx);
while (!pr.done) { while (!pr.done) {
grpc_pollset_worker *worker = NULL; grpc_pollset_worker *worker = NULL;
if (!GRPC_LOG_IF_ERROR( if (!GRPC_LOG_IF_ERROR(
@ -240,6 +241,7 @@ int grpc_pick_port_using_server(void) {
&pr.response); &pr.response);
grpc_resource_quota_unref_internal(&exec_ctx, resource_quota); grpc_resource_quota_unref_internal(&exec_ctx, resource_quota);
gpr_mu_lock(pr.mu); gpr_mu_lock(pr.mu);
grpc_exec_ctx_flush(&exec_ctx);
while (pr.port == -1) { while (pr.port == -1) {
grpc_pollset_worker *worker = NULL; grpc_pollset_worker *worker = NULL;
if (!GRPC_LOG_IF_ERROR( if (!GRPC_LOG_IF_ERROR(

Loading…
Cancel
Save