Merge pull request #115 from stanley-cheung/master

Fixed segfault when calling grpc_error_get_status
This commit is contained in:
Stanley Cheung 2017-12-04 21:42:39 -08:00 committed by GitHub
commit a85efc2212
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 0 deletions

View File

@ -151,6 +151,7 @@ void GrpcBackend::OnResponseMessage(bool result) {
if (response_buffer_ == nullptr) {
// Receives the GRPC response status.
grpc_op ops[1];
memset(ops, 0, sizeof(ops));
ops[0].op = GRPC_OP_RECV_STATUS_ON_CLIENT;
ops[0].data.recv_status_on_client.status = &status_code_;
ops[0].data.recv_status_on_client.status_details = &status_details_;