aboutsummaryrefslogtreecommitdiffhomepage
path: root/test
diff options
context:
space:
mode:
authorGravatar Craig Tiller <ctiller@google.com>2017-05-24 00:03:19 +0000
committerGravatar Craig Tiller <ctiller@google.com>2017-05-24 00:03:19 +0000
commit2d485f0396ec3d84b7899526229f41a923434946 (patch)
tree6b933d76e0cdff1f02fac5e3e04cd7a15d6a57ae /test
parent8c4f5cd2c1f4cebd664a867b71cac4a599ef03e6 (diff)
Fix threading assumptions in test
Diffstat (limited to 'test')
-rw-r--r--test/core/iomgr/endpoint_tests.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/test/core/iomgr/endpoint_tests.c b/test/core/iomgr/endpoint_tests.c
index e274796e23..85ba85373b 100644
--- a/test/core/iomgr/endpoint_tests.c
+++ b/test/core/iomgr/endpoint_tests.c
@@ -265,7 +265,10 @@ static void read_and_write_test(grpc_endpoint_test_config config,
static void inc_on_failure(grpc_exec_ctx *exec_ctx, void *arg,
grpc_error *error) {
+ gpr_mu_lock(g_mu);
*(int *)arg += (error != GRPC_ERROR_NONE);
+ GPR_ASSERT(GRPC_LOG_IF_ERROR("kick", grpc_pollset_kick(g_pollset, NULL)));
+ gpr_mu_unlock(g_mu);
}
static void wait_for_fail_count(grpc_exec_ctx *exec_ctx, int *fail_count,