remove the checking of empty string for recvCompress
This commit is contained in:
@ -284,9 +284,6 @@ func checkRecvPayload(pf payloadFormat, recvCompress string, dc Decompressor) er
|
|||||||
switch pf {
|
switch pf {
|
||||||
case compressionNone:
|
case compressionNone:
|
||||||
case compressionMade:
|
case compressionMade:
|
||||||
if recvCompress == "" {
|
|
||||||
return transport.StreamErrorf(codes.Unimplemented, "grpc: invalid grpc-encoding with compression enabled")
|
|
||||||
}
|
|
||||||
if dc == nil || recvCompress != dc.Type() {
|
if dc == nil || recvCompress != dc.Type() {
|
||||||
return transport.StreamErrorf(codes.Unimplemented, "grpc: Decompressor is not installed for grpc-encoding %q", recvCompress)
|
return transport.StreamErrorf(codes.Unimplemented, "grpc: Decompressor is not installed for grpc-encoding %q", recvCompress)
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user