diff --git a/src/ruby/ext/grpc/rb_completion_queue.c b/src/ruby/ext/grpc/rb_completion_queue.c index fef55282d4334..d45b8199650a7 100644 --- a/src/ruby/ext/grpc/rb_completion_queue.c +++ b/src/ruby/ext/grpc/rb_completion_queue.c @@ -85,10 +85,8 @@ grpc_event rb_completion_queue_pluck(grpc_completion_queue* queue, void* tag, grpc_absl_log_str(GPR_DEBUG, "CQ pluck loop begin: ", reason); do { next_call.interrupted = 0; - rb_nogvl(grpc_rb_completion_queue_pluck_no_gil, - (void*)&next_call, unblock_func, - (void*)&next_call, - RB_NOGVL_OFFLOAD_SAFE); + rb_nogvl(grpc_rb_completion_queue_pluck_no_gil, (void*)&next_call, + unblock_func, (void*)&next_call, RB_NOGVL_OFFLOAD_SAFE); if (next_call.event.type != GRPC_QUEUE_TIMEOUT) break; } while (next_call.interrupted); grpc_absl_log_str(GPR_DEBUG, "CQ pluck loop done: ", reason); diff --git a/src/ruby/ext/grpc/rb_event_thread.c b/src/ruby/ext/grpc/rb_event_thread.c index a3b0c3938ad28..92de179eb9321 100644 --- a/src/ruby/ext/grpc/rb_event_thread.c +++ b/src/ruby/ext/grpc/rb_event_thread.c @@ -127,9 +127,9 @@ static VALUE grpc_rb_event_thread(void* arg) { #ifdef RB_NOGVL_OFFLOAD_SAFE #endif - event = (grpc_rb_event*)rb_nogvl( - grpc_rb_wait_for_event_no_gil, NULL, grpc_rb_event_unblocking_func, - NULL, RB_NOGVL_OFFLOAD_SAFE); + event = (grpc_rb_event*)rb_nogvl(grpc_rb_wait_for_event_no_gil, NULL, + grpc_rb_event_unblocking_func, NULL, + RB_NOGVL_OFFLOAD_SAFE); if (event == NULL) { // Indicates that the thread needs to shut down break; @@ -163,8 +163,8 @@ void grpc_rb_event_queue_thread_stop() { "GRPC_RUBY: call credentials thread stop: thread not running"); return; } - rb_nogvl(grpc_rb_event_unblocking_func_wrapper, NULL, NULL, - NULL, RB_NOGVL_OFFLOAD_SAFE); + rb_nogvl(grpc_rb_event_unblocking_func_wrapper, NULL, NULL, NULL, + RB_NOGVL_OFFLOAD_SAFE); rb_funcall(g_event_thread, rb_intern("join"), 0); g_event_thread = Qnil; }