From 9c6ec8aab653605360a76e7065bb60fe7d59f083 Mon Sep 17 00:00:00 2001 From: Robin Getz Date: Mon, 10 Aug 2026 19:55:46 -0400 Subject: [PATCH] demodchirpchat: initialize missing settings members Initialize m_rollupState to nullptr in the constructor and set m_autoNbSymbolsMax to false in resetToDefaults(). This ensures the optional rollup state pointer and the automatic message length setting have defined initial values rather than relying on uninitialized storage. Pointed out by cppcheck. Signed-off-by: Robin Getz --- plugins/channelrx/demodchirpchat/chirpchatdemodsettings.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/plugins/channelrx/demodchirpchat/chirpchatdemodsettings.cpp b/plugins/channelrx/demodchirpchat/chirpchatdemodsettings.cpp index fec2de46b..5bdef17a8 100644 --- a/plugins/channelrx/demodchirpchat/chirpchatdemodsettings.cpp +++ b/plugins/channelrx/demodchirpchat/chirpchatdemodsettings.cpp @@ -59,7 +59,8 @@ const int ChirpChatDemodSettings::oversampling = 2; ChirpChatDemodSettings::ChirpChatDemodSettings() : m_inputFrequencyOffset(0), m_channelMarker(0), - m_spectrumGUI(0) + m_spectrumGUI(0), + m_rollupState(nullptr) { resetToDefaults(); } @@ -74,6 +75,7 @@ void ChirpChatDemodSettings::resetToDefaults() m_fftWindow = FFTWindow::Rectangle; m_eomSquelchTenths = 60; m_nbSymbolsMax = 255; + m_autoNbSymbolsMax = false; m_preambleChirps = 8; m_packetLength = 32; m_nbParityBits = 1;