diff --git a/duplex_http_call.go b/duplex_http_call.go index 78bf13c2..b5937fd1 100644 --- a/duplex_http_call.go +++ b/duplex_http_call.go @@ -168,6 +168,8 @@ func (d *duplexHTTPCall) CloseWrite() error { // response to read from. if d.requestSent.CompareAndSwap(false, true) { go d.makeRequest() + // We never setup a request body, so it's effectively already closed. + // So nothing else to do. return nil } // The user calls CloseWrite to indicate that they're done sending data. It's diff --git a/protocol_connect.go b/protocol_connect.go index 45577d82..6828ab4d 100644 --- a/protocol_connect.go +++ b/protocol_connect.go @@ -1408,7 +1408,7 @@ func connectValidateStreamResponseContentType(requestCodecName string, streamTyp CodeUnknown, "invalid content-type: %q; expecting %q", responseContentType, - connectUnaryContentTypePrefix+requestCodecName, + connectStreamingContentTypePrefix+requestCodecName, ) } responseCodecName := connectCodecFromContentType(