From 65dc673bef36c093c545dc14fe6a68cefa46804c Mon Sep 17 00:00:00 2001 From: Robin Getz Date: Mon, 10 Aug 2026 19:37:10 -0400 Subject: [PATCH] demodatv: initialize uninitialized sync detection members Initialize the field and vertical sync detection sample counters and the previous sample value in ATVDemodSink. This gives the video synchronization state defined initial values when the sink is constructed and removes the uninitialized member warnings reported by cppcheck. Signed-off-by: Robin Getz --- plugins/channelrx/demodatv/atvdemodsink.cpp | 3 +++ 1 file changed, 3 insertions(+) diff --git a/plugins/channelrx/demodatv/atvdemodsink.cpp b/plugins/channelrx/demodatv/atvdemodsink.cpp index 8c8b85ba7..ef3346d94 100644 --- a/plugins/channelrx/demodatv/atvdemodsink.cpp +++ b/plugins/channelrx/demodatv/atvdemodsink.cpp @@ -38,6 +38,8 @@ ATVDemodSink::ATVDemodSink() : m_numberSamplesPerHTop(0), m_fieldIndex(0), m_synchroSamples(0), + m_fieldDetectSampleCount(0), + m_vSyncDetectSampleCount(0), m_effMin(20.0f), m_effMax(-20.0f), m_ampMin(-1.0f), @@ -50,6 +52,7 @@ ATVDemodSink::ATVDemodSink() : m_lineIndex(0), m_hSyncShift(0.0f), m_hSyncErrorCount(0), + prevSample(0.0f), m_ampAverage(4800), m_bfoPLL(200/1000000, 100/1000000, 0.01), m_bfoFilter(200.0, 1000000.0, 0.9),