Merge pull request #39930 from tg-at-google:patch-7
PiperOrigin-RevId: 314568776 Change-Id: I15dac9e000e40c9b13193a7ca32f59e12ce25184
This commit is contained in:
commit
442f5e2b80
@ -72,7 +72,8 @@ bool SerializeToBufferDeterministic(const protobuf::MessageLite& msg,
|
|||||||
protobuf::io::CodedOutputStream output_stream(&array_stream);
|
protobuf::io::CodedOutputStream output_stream(&array_stream);
|
||||||
output_stream.SetSerializationDeterministic(true);
|
output_stream.SetSerializationDeterministic(true);
|
||||||
msg.SerializeWithCachedSizes(&output_stream);
|
msg.SerializeWithCachedSizes(&output_stream);
|
||||||
return !output_stream.HadError() && size == output_stream.ByteCount();
|
return !output_stream.HadError() &&
|
||||||
|
size == static_cast<size_t>(output_stream.ByteCount());
|
||||||
}
|
}
|
||||||
|
|
||||||
bool AreSerializedProtosEqual(const protobuf::MessageLite& x,
|
bool AreSerializedProtosEqual(const protobuf::MessageLite& x,
|
||||||
|
Loading…
x
Reference in New Issue
Block a user