|
|
@ -32,10 +32,10 @@ |
|
|
|
*/ |
|
|
|
*/ |
|
|
|
|
|
|
|
|
|
|
|
#include <ruby/ruby.h> |
|
|
|
#include <ruby/ruby.h> |
|
|
|
|
|
|
|
|
|
|
|
#include "rb_grpc_imports.generated.h" |
|
|
|
#include "rb_grpc_imports.generated.h" |
|
|
|
#include "rb_call_credentials.h" |
|
|
|
#include "rb_call_credentials.h" |
|
|
|
|
|
|
|
|
|
|
|
#include <ruby/ruby.h> |
|
|
|
|
|
|
|
#include <ruby/thread.h> |
|
|
|
#include <ruby/thread.h> |
|
|
|
|
|
|
|
|
|
|
|
#include <grpc/grpc.h> |
|
|
|
#include <grpc/grpc.h> |
|
|
@ -86,11 +86,11 @@ static VALUE grpc_rb_call_credentials_callback_rescue(VALUE args, |
|
|
|
rb_funcall(exception_object, rb_intern("backtrace"), 0), |
|
|
|
rb_funcall(exception_object, rb_intern("backtrace"), 0), |
|
|
|
rb_intern("join"), |
|
|
|
rb_intern("join"), |
|
|
|
1, rb_str_new2("\n\tfrom ")); |
|
|
|
1, rb_str_new2("\n\tfrom ")); |
|
|
|
VALUE exception_info = rb_funcall(exception_object, rb_intern("to_s"), 0); |
|
|
|
VALUE rb_exception_info = rb_funcall(exception_object, rb_intern("to_s"), 0); |
|
|
|
const char *exception_classname = rb_obj_classname(exception_object); |
|
|
|
const char *exception_classname = rb_obj_classname(exception_object); |
|
|
|
(void)args; |
|
|
|
(void)args; |
|
|
|
gpr_log(GPR_INFO, "Call credentials callback failed: %s: %s\n%s", |
|
|
|
gpr_log(GPR_INFO, "Call credentials callback failed: %s: %s\n%s", |
|
|
|
exception_classname, StringValueCStr(exception_info), |
|
|
|
exception_classname, StringValueCStr(rb_exception_info), |
|
|
|
StringValueCStr(backtrace)); |
|
|
|
StringValueCStr(backtrace)); |
|
|
|
rb_hash_aset(result, rb_str_new2("metadata"), Qnil); |
|
|
|
rb_hash_aset(result, rb_str_new2("metadata"), Qnil); |
|
|
|
/* Currently only gives the exception class name. It should be possible get
|
|
|
|
/* Currently only gives the exception class name. It should be possible get
|
|
|
|