Fix for 32-bit architectures (#1471)

This commit is contained in:
dfawley
2017-08-25 15:09:36 -07:00
committed by GitHub
parent 39596153a9
commit 2b9fb51017

View File

@ -317,7 +317,7 @@ func encode(c Codec, msg interface{}, cp Compressor, cbuf *bytes.Buffer, outPayl
}
}
if len(b) > math.MaxUint32 {
if uint(len(b)) > math.MaxUint32 {
return nil, nil, Errorf(codes.ResourceExhausted, "grpc: message too large (%d bytes)", len(b))
}