From cc8bbac4a43f535dbda21c882afc1d0a47e8d9a1 Mon Sep 17 00:00:00 2001 From: Robin Getz Date: Wed, 14 Oct 2026 19:01:16 -0400 Subject: [PATCH] test_psk31: Fix signedness warning in sample loop Resolve GCC -Wsign-compare by matching the loop index type to the unsigned size returned by the container. This avoids signed/unsigned comparison errors and potential incorrect loop bounds when processing sample buffers. Signed-off-by: Robin Getz --- sdrbench/test_psk31.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sdrbench/test_psk31.cpp b/sdrbench/test_psk31.cpp index 5e529603d..7fa306aa9 100644 --- a/sdrbench/test_psk31.cpp +++ b/sdrbench/test_psk31.cpp @@ -338,7 +338,7 @@ QString runChannelTrial( } constexpr int blockSize = 1000; - for (int i = 0; i < samples.size(); i += blockSize) { + for (std::size_t i = 0; i < samples.size(); i += blockSize) { demod.feed(samples.begin() + i, samples.begin() + std::min(i + blockSize, samples.size())); }