remove the checking of empty string for recvCompress

This commit is contained in:
iamqizhao
2016-05-11 11:01:26 -07:00
parent b506f13d5b
commit e0f9f26e85

View File

@ -284,9 +284,6 @@ func checkRecvPayload(pf payloadFormat, recvCompress string, dc Decompressor) er
switch pf {
case compressionNone:
case compressionMade:
if recvCompress == "" {
return transport.StreamErrorf(codes.Unimplemented, "grpc: invalid grpc-encoding with compression enabled")
}
if dc == nil || recvCompress != dc.Type() {
return transport.StreamErrorf(codes.Unimplemented, "grpc: Decompressor is not installed for grpc-encoding %q", recvCompress)
}