From f57e6d35689a0b57f1323f20533925fc00b67bd6 Mon Sep 17 00:00:00 2001 From: Robin Getz Date: Sun, 26 Jul 2026 14:54:12 -0400 Subject: [PATCH] DATV: Replace DVB-S2 pilot VLA buffers with std::vector Replace variable-length arrays used for DVB-S2 pilot symbol matching with std::vector allocations. Use vector::data() when passing buffers to the existing pointer-based match_ph_amp() function. This removes non-standard VLA usage and improves C++ portability without changing behavior. Signed-off-by: Robin Getz --- plugins/channelrx/demoddatv/leansdr/dvbs2.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/plugins/channelrx/demoddatv/leansdr/dvbs2.h b/plugins/channelrx/demoddatv/leansdr/dvbs2.h index b89065505..03061a5c7 100644 --- a/plugins/channelrx/demoddatv/leansdr/dvbs2.h +++ b/plugins/channelrx/demoddatv/leansdr/dvbs2.h @@ -1610,13 +1610,13 @@ struct s2_frame_receiver : runnable float interp_match_sof(sampler_state *pss) { - std::complex symbols[pilot.LENGTH]; + std::vector> symbols(pilot.LENGTH); for (int i=0; igain; } - return match_ph_amp(sof.symbols, symbols, sof.LENGTH, pss); + return match_ph_amp(sof.symbols, symbols.data(), sof.LENGTH, pss); } // Estimate phase and amplitude from known symbols.