From 40737d67ee93f3c60be1f0ff6486d6f045646312 Mon Sep 17 00:00:00 2001 From: ncteisen Date: Mon, 13 Nov 2017 08:02:35 -0800 Subject: Add error string to recv status API --- include/grpc++/impl/codegen/call.h | 2 ++ 1 file changed, 2 insertions(+) (limited to 'include/grpc++') diff --git a/include/grpc++/impl/codegen/call.h b/include/grpc++/impl/codegen/call.h index 1a988297dc..91f45b3147 100644 --- a/include/grpc++/impl/codegen/call.h +++ b/include/grpc++/impl/codegen/call.h @@ -579,6 +579,7 @@ class CallOpClientRecvStatus { op->data.recv_status_on_client.trailing_metadata = metadata_map_->arr(); op->data.recv_status_on_client.status = &status_code_; op->data.recv_status_on_client.status_details = &error_message_; + op->data.recv_status_on_client.error_string = &error_string_; op->flags = 0; op->reserved = NULL; } @@ -605,6 +606,7 @@ class CallOpClientRecvStatus { Status* recv_status_; grpc_status_code status_code_; grpc_slice error_message_; + const char* error_string_; }; /// An abstract collection of call ops, used to generate the -- cgit v1.2.3 From 0354c22d402647b5ba532038511a4849c53b2b0b Mon Sep 17 00:00:00 2001 From: ncteisen Date: Wed, 15 Nov 2017 18:22:11 -0800 Subject: Save C++ for follow up PR --- include/grpc++/impl/codegen/call.h | 2 -- 1 file changed, 2 deletions(-) (limited to 'include/grpc++') diff --git a/include/grpc++/impl/codegen/call.h b/include/grpc++/impl/codegen/call.h index 91f45b3147..1a988297dc 100644 --- a/include/grpc++/impl/codegen/call.h +++ b/include/grpc++/impl/codegen/call.h @@ -579,7 +579,6 @@ class CallOpClientRecvStatus { op->data.recv_status_on_client.trailing_metadata = metadata_map_->arr(); op->data.recv_status_on_client.status = &status_code_; op->data.recv_status_on_client.status_details = &error_message_; - op->data.recv_status_on_client.error_string = &error_string_; op->flags = 0; op->reserved = NULL; } @@ -606,7 +605,6 @@ class CallOpClientRecvStatus { Status* recv_status_; grpc_status_code status_code_; grpc_slice error_message_; - const char* error_string_; }; /// An abstract collection of call ops, used to generate the -- cgit v1.2.3 From 14c60f1d12dd9b4ac67ab8addae0c27f5971e55a Mon Sep 17 00:00:00 2001 From: ncteisen Date: Wed, 15 Nov 2017 20:26:50 -0800 Subject: Fix segfault --- include/grpc++/impl/codegen/call.h | 1 + 1 file changed, 1 insertion(+) (limited to 'include/grpc++') diff --git a/include/grpc++/impl/codegen/call.h b/include/grpc++/impl/codegen/call.h index 1a988297dc..41e95866cf 100644 --- a/include/grpc++/impl/codegen/call.h +++ b/include/grpc++/impl/codegen/call.h @@ -579,6 +579,7 @@ class CallOpClientRecvStatus { op->data.recv_status_on_client.trailing_metadata = metadata_map_->arr(); op->data.recv_status_on_client.status = &status_code_; op->data.recv_status_on_client.status_details = &error_message_; + op->data.recv_status_on_client.error_string = nullptr; op->flags = 0; op->reserved = NULL; } -- cgit v1.2.3