From 9c8d90f4cfa5f3162e116bcac5b6d4044495cbc3 Mon Sep 17 00:00:00 2001 From: Robin Getz Date: Mon, 10 Aug 2026 19:48:36 -0400 Subject: [PATCH] demodbfm: initialize RDS radio text A/B flag Initialize m_radiotext_AB_flag in the RDSParser constructor to ensure the radio text state is defined before the first Group 2 update. Keep the flag out of clearUpdateFlags() because it is persistent parser state, not a transient update flag. Resetting it when update flags are cleared could incorrectly appear as an A/B transition and cause stale radio text handling. Pointed out by cppcheck. Signed-off-by: Robin Getz --- plugins/channelrx/demodbfm/rdsparser.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/plugins/channelrx/demodbfm/rdsparser.cpp b/plugins/channelrx/demodbfm/rdsparser.cpp index b02f8742b..b0dde7186 100644 --- a/plugins/channelrx/demodbfm/rdsparser.cpp +++ b/plugins/channelrx/demodbfm/rdsparser.cpp @@ -232,7 +232,8 @@ const std::string RDSParser::label_descriptions[16] = { "RFU (Reserved for future use)" }; -RDSParser::RDSParser() +RDSParser::RDSParser(): + m_radiotext_AB_flag(false) { clearAllFields(); }