mirror of
https://github.com/f4exb/sdrangel.git
synced 2026-08-19 18:03:39 -04:00
modemm17: initialize SyncWord sample buffer
Initialize samples_ during construction so the sample buffer is not left indeterminate. The existing triggered_ state ensures the buffer is initialized with fill() before its contents are used, so this is defensive initialization rather than a functional fix. Detected by cppcheck. Signed-off-by: Robin Getz <rgetz503@gmail.com>
This commit is contained in:
@@ -135,6 +135,7 @@ struct SyncWord
|
||||
float magnitude_2 = std::numeric_limits<float>::lowest()
|
||||
) :
|
||||
sync_word_(std::move(sync_word)),
|
||||
samples_{},
|
||||
magnitude_1_(magnitude_1),
|
||||
magnitude_2_(magnitude_2)
|
||||
{}
|
||||
|
||||
Reference in New Issue
Block a user