Skip to content
Snippets Groups Projects
Commit d6887e0e authored by Craig Tiller's avatar Craig Tiller
Browse files

Some fixes

parent 3cb3447e
No related branches found
No related tags found
No related merge requests found
......@@ -115,6 +115,8 @@ static void maybe_spawn_locked() {
static void executor_push(grpc_exec_ctx *exec_ctx, grpc_closure *closure,
grpc_error *error) {
gpr_mu_lock(&g_executor.mu);
GPR_ASSERT(closure->scheduler == grpc_executor_scheduler);
closure->scheduler = grpc_schedule_on_exec_ctx;
if (g_executor.shutting_down == 0) {
grpc_closure_list_append(&g_executor.closures, closure, error);
maybe_spawn_locked();
......
......@@ -342,8 +342,8 @@ static void tcp_client_connect_impl(grpc_exec_ctx *exec_ctx,
addr_str = NULL;
gpr_mu_init(&ac->mu);
ac->refs = 2;
ac->write_closure.cb = on_writable;
ac->write_closure.cb_arg = ac;
grpc_closure_init(&ac->write_closure, on_writable, ac,
grpc_schedule_on_exec_ctx);
ac->channel_args = grpc_channel_args_copy(channel_args);
if (grpc_tcp_trace) {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment