From 2893cdf5dfe299f7ea73fa7e19466d0596c1b108 Mon Sep 17 00:00:00 2001 From: Robin Getz Date: Mon, 26 Oct 2026 17:40:52 -0400 Subject: [PATCH] samplemimo/limesdrmimo: Initialize output buffer and interpolation Initialize m_buf to nullptr before allocating the sample buffer and initialize m_log2Interp to prevent use of indeterminate state. Identified by cppcheck. Signed-off-by: Robin Getz --- plugins/samplemimo/limesdrmimo/limesdrmothread.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/plugins/samplemimo/limesdrmimo/limesdrmothread.cpp b/plugins/samplemimo/limesdrmimo/limesdrmothread.cpp index 4c9e8951c..b9257d87e 100644 --- a/plugins/samplemimo/limesdrmimo/limesdrmothread.cpp +++ b/plugins/samplemimo/limesdrmimo/limesdrmothread.cpp @@ -25,7 +25,9 @@ LimeSDRMOThread::LimeSDRMOThread(lms_stream_t* stream0, lms_stream_t* stream1, Q m_running(false), m_stream0(stream0), m_stream1(stream1), - m_sampleFifo(nullptr) + m_buf(nullptr), + m_sampleFifo(nullptr), + m_log2Interp(0) { qDebug("LimeSDRMOThread::LimeSDRMOThread"); m_buf = new qint16[2*DeviceLimeSDR::blockSize*2];