| 378 | } |
| 379 | |
| 380 | Status ServerNegotiation::SendError(ErrorStatusPB::RpcErrorCodePB code, const Status& err) { |
| 381 | DCHECK(!err.ok()); |
| 382 | |
| 383 | // Create header with negotiation-specific callId |
| 384 | ResponseHeader header; |
| 385 | header.set_call_id(kNegotiateCallId); |
| 386 | header.set_is_error(true); |
| 387 | |
| 388 | // Get RPC error code from Status object |
| 389 | ErrorStatusPB msg; |
| 390 | msg.set_code(code); |
| 391 | msg.set_message(err.ToString()); |
| 392 | |
| 393 | TRACE("Sending RPC error: $0: $1", ErrorStatusPB::RpcErrorCodePB_Name(code), err.ToString()); |
| 394 | return SendFramedMessageBlocking(socket_.get(), header, msg, deadline_); |
| 395 | } |
| 396 | |
| 397 | Status ServerNegotiation::ValidateConnectionHeader(faststring* recv_buf) { |
| 398 | TRACE("Waiting for connection header"); |
nothing calls this directly
no test coverage detected