diff options
author | Eric Richardson <ewr@squareup.com> | 2016-04-21 14:46:59 -0400 |
---|---|---|
committer | Eric Richardson <ewr@squareup.com> | 2016-04-21 14:46:59 -0400 |
commit | 336b744eff21c447fe783ae7bab491980c6d93d2 (patch) | |
tree | 9b3d4f721e057643bed0b4c90c8a5972e1c05ed8 /src/ruby/ext | |
parent | bdfaf482a339e988a6613222d468a8826eea36c8 (diff) |
Fix a mixed declaration warning in the grpc_rb_call_get_peer_cert method
Diffstat (limited to 'src/ruby/ext')
-rw-r--r-- | src/ruby/ext/grpc/rb_call.c | 16 |
1 files changed, 9 insertions, 7 deletions
diff --git a/src/ruby/ext/grpc/rb_call.c b/src/ruby/ext/grpc/rb_call.c index c8be2773fd..48c49a21e9 100644 --- a/src/ruby/ext/grpc/rb_call.c +++ b/src/ruby/ext/grpc/rb_call.c @@ -227,14 +227,16 @@ static VALUE grpc_rb_call_get_peer_cert(VALUE self) { return Qnil; } - grpc_auth_property_iterator it = - grpc_auth_context_find_properties_by_name(ctx, GRPC_X509_PEM_CERT_PROPERTY_NAME); - const grpc_auth_property *prop = grpc_auth_property_iterator_next(&it); - if (prop == NULL) { - return Qnil; - } + { + grpc_auth_property_iterator it = + grpc_auth_context_find_properties_by_name(ctx, GRPC_X509_PEM_CERT_PROPERTY_NAME); + const grpc_auth_property *prop = grpc_auth_property_iterator_next(&it); + if (prop == NULL) { + return Qnil; + } - res = rb_str_new2(prop->value); + res = rb_str_new2(prop->value); + } grpc_auth_context_release(ctx); |