From d6acffba7bf67e8f928acf1cc676056919ad19e3 Mon Sep 17 00:00:00 2001 From: Josh Humphries Date: Thu, 15 Sep 2022 13:37:59 -0400 Subject: [PATCH] use normal conditional --- src/google/protobuf/io/tokenizer.cc | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/src/google/protobuf/io/tokenizer.cc b/src/google/protobuf/io/tokenizer.cc index 127fb5a40258..d14c5a19268d 100644 --- a/src/google/protobuf/io/tokenizer.cc +++ b/src/google/protobuf/io/tokenizer.cc @@ -1003,11 +1003,12 @@ bool Tokenizer::ParseInteger(const std::string& text, uint64_t max_value, double Tokenizer::ParseFloat(const std::string& text) { double result; - GOOGLE_LOG_IF(DFATAL, - !TryParseFloat(text, &result)) - << " Tokenizer::ParseFloat() passed text that could not have been" - " tokenized as a float: " - << absl::CEscape(text); + if (!TryParseFloat(text, &result)) { + LOG(DFATAL) + << " Tokenizer::ParseFloat() passed text that could not have been" + " tokenized as a float: " + << absl::CEscape(text); + } return result; }