From 75d5c0f024438944425cf1bd3163b07c6f6e55b5 Mon Sep 17 00:00:00 2001 From: Alistair Veitch Date: Tue, 2 Feb 2016 09:43:02 -0800 Subject: post merge --- src/ruby/ext/grpc/rb_call.c | 7 ++++--- src/ruby/ext/grpc/rb_call_credentials.c | 2 ++ src/ruby/ext/grpc/rb_event_thread.c | 3 +++ 3 files changed, 9 insertions(+), 3 deletions(-) (limited to 'src/ruby/ext') diff --git a/src/ruby/ext/grpc/rb_call.c b/src/ruby/ext/grpc/rb_call.c index 43adafb73f..07864ebf59 100644 --- a/src/ruby/ext/grpc/rb_call.c +++ b/src/ruby/ext/grpc/rb_call.c @@ -525,12 +525,13 @@ typedef struct run_batch_stack { grpc_status_code recv_status; char *recv_status_details; size_t recv_status_details_capacity; - uint write_flag; + unsigned write_flag; } run_batch_stack; /* grpc_run_batch_stack_init ensures the run_batch_stack is properly * initialized */ -static void grpc_run_batch_stack_init(run_batch_stack *st, uint write_flag) { +static void grpc_run_batch_stack_init(run_batch_stack *st, + unsigned write_flag) { MEMZERO(st, run_batch_stack, 1); grpc_metadata_array_init(&st->send_metadata); grpc_metadata_array_init(&st->send_trailing_metadata); @@ -696,7 +697,7 @@ static VALUE grpc_rb_call_run_batch(VALUE self, VALUE cqueue, VALUE tag, grpc_call_error err; VALUE result = Qnil; VALUE rb_write_flag = rb_ivar_get(self, id_write_flag); - uint write_flag = 0; + unsigned write_flag = 0; TypedData_Get_Struct(self, grpc_call, &grpc_call_data_type, call); /* Validate the ops args, adding them to a ruby array */ diff --git a/src/ruby/ext/grpc/rb_call_credentials.c b/src/ruby/ext/grpc/rb_call_credentials.c index 4d719d7541..ebcc6592c2 100644 --- a/src/ruby/ext/grpc/rb_call_credentials.c +++ b/src/ruby/ext/grpc/rb_call_credentials.c @@ -79,6 +79,7 @@ static VALUE grpc_rb_call_credentials_callback(VALUE callback_args) { static VALUE grpc_rb_call_credentials_callback_rescue(VALUE args, VALUE exception_object) { VALUE result = rb_hash_new(); + (void)args; rb_hash_aset(result, rb_str_new2("metadata"), Qnil); /* Currently only gives the exception class name. It should be possible get more details */ @@ -132,6 +133,7 @@ static void grpc_rb_call_credentials_plugin_get_metadata( } static void grpc_rb_call_credentials_plugin_destroy(void *state) { + (void)state; // Not sure what needs to be done here } diff --git a/src/ruby/ext/grpc/rb_event_thread.c b/src/ruby/ext/grpc/rb_event_thread.c index 95af091317..516f0bdad2 100644 --- a/src/ruby/ext/grpc/rb_event_thread.c +++ b/src/ruby/ext/grpc/rb_event_thread.c @@ -102,6 +102,7 @@ static void grpc_rb_event_queue_destroy() { static void *grpc_rb_wait_for_event_no_gil(void *param) { grpc_rb_event *event = NULL; + (void)param; gpr_mu_lock(&event_queue.mu); while ((event = grpc_rb_event_queue_dequeue()) == NULL) { gpr_cv_wait(&event_queue.cv, @@ -117,6 +118,7 @@ static void *grpc_rb_wait_for_event_no_gil(void *param) { } static void grpc_rb_event_unblocking_func(void *arg) { + (void)arg; gpr_mu_lock(&event_queue.mu); event_queue.abort = true; gpr_cv_signal(&event_queue.cv); @@ -127,6 +129,7 @@ static void grpc_rb_event_unblocking_func(void *arg) { * events */ static VALUE grpc_rb_event_thread(VALUE arg) { grpc_rb_event *event; + (void)arg; while(true) { event = (grpc_rb_event*)rb_thread_call_without_gvl( grpc_rb_wait_for_event_no_gil, NULL, -- cgit v1.2.3