From 73117ce19373ec4c99b9ab81732279675c0053ae Mon Sep 17 00:00:00 2001 From: Andrei Litvin Date: Thu, 6 Jul 2023 12:41:51 -0400 Subject: [PATCH] Make clang-tidy happy --- src/lib/format/protocol_decoder.cpp | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/lib/format/protocol_decoder.cpp b/src/lib/format/protocol_decoder.cpp index e980f344404d28..8c3b352133902a 100644 --- a/src/lib/format/protocol_decoder.cpp +++ b/src/lib/format/protocol_decoder.cpp @@ -412,7 +412,8 @@ void PayloadDecoderBase::NextFromContentRead(PayloadEntry & entry) ExitContainer(entry); return; } - else if (err != CHIP_NO_ERROR) + + if (err != CHIP_NO_ERROR) { mValueBuilder.Reset().AddFormat("ERROR on TLV Next: %" CHIP_ERROR_FORMAT, err.Format()); entry = PayloadEntry::SimpleValue("TLV_ERR", mValueBuilder.c_str()); @@ -546,7 +547,8 @@ void PayloadDecoderBase::NextFromValueRead(PayloadEntry & entry) ExitContainer(entry); return; } - else if (err != CHIP_NO_ERROR) + + if (err != CHIP_NO_ERROR) { mValueBuilder.Reset().AddFormat("ERROR on TLV Next: %" CHIP_ERROR_FORMAT, err.Format()); entry = PayloadEntry::SimpleValue("TLV_ERR", mValueBuilder.c_str());