misc: Replace a deprecated method in protoio.cc.
authorGabe Black <gabeblack@google.com>
Sat, 25 Apr 2020 07:16:45 +0000 (00:16 -0700)
committerGabe Black <gabeblack@google.com>
Mon, 27 Apr 2020 21:46:28 +0000 (21:46 +0000)
A warning says that ByteSize is now deprecated, and should be replaced
with ByteSizeLong. This change does that.

Change-Id: I0b1aef733c509a73a0af9c39b359d39579d1fd37
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/28185
Reviewed-by: Jason Lowe-Power <power.jg@gmail.com>
Maintainer: Jason Lowe-Power <power.jg@gmail.com>
Tested-by: kokoro <noreply+kokoro@google.com>
src/proto/protoio.cc

index 93c57493fdf749683048448f6e945c1b0060fcc9..2efcc2744ec1d09d35666ffe5891b509bf19fcc2 100644 (file)
@@ -87,7 +87,7 @@ ProtoOutputStream::write(const Message& msg)
     io::CodedOutputStream codedStream(zeroCopyStream);
 
     // Write the size of the message to the stream
-    codedStream.WriteVarint32(msg.ByteSize());
+    codedStream.WriteVarint32(msg.ByteSizeLong());
 
     // Write the message itself to the stream
     msg.SerializeWithCachedSizes(&codedStream);