From 10e000b4a628098267872c2386bd1dabed6ff8a6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Krzysztof=20Kosi=C5=84ski?= Date: Sat, 6 Aug 2022 08:37:53 +0000 Subject: simpleperf: fix deprecated protobuf API usage. Bug: 203713560 Test: presubmit, boot aosp_raven Change-Id: I0da61e80bdf03a954accefbd88b9f2788ef08f38 --- simpleperf/cmd_report_sample.cpp | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/simpleperf/cmd_report_sample.cpp b/simpleperf/cmd_report_sample.cpp index dc2a3d44..dfaf5a3f 100644 --- a/simpleperf/cmd_report_sample.cpp +++ b/simpleperf/cmd_report_sample.cpp @@ -372,8 +372,7 @@ bool ReportSampleCommand::DumpProtobufReport(const std::string& filename) { // files[file_id] is the number of symbols in the file. std::vector files; uint32_t max_message_size = 64 * (1 << 20); - uint32_t warning_message_size = 512 * (1 << 20); - coded_is.SetTotalBytesLimit(max_message_size, warning_message_size); + coded_is.SetTotalBytesLimit(max_message_size); while (true) { uint32_t size; if (!coded_is.ReadLittleEndian32(&size)) { @@ -386,7 +385,7 @@ bool ReportSampleCommand::DumpProtobufReport(const std::string& filename) { // Handle files having large symbol table. if (size > max_message_size) { max_message_size = size; - coded_is.SetTotalBytesLimit(max_message_size, warning_message_size); + coded_is.SetTotalBytesLimit(max_message_size); } auto limit = coded_is.PushLimit(size); proto::Record proto_record; -- cgit v1.2.3