aboutsummaryrefslogtreecommitdiffstats
path: root/common
diff options
context:
space:
mode:
authorChris Robinson <[email protected]>2023-12-20 01:53:27 -0800
committerChris Robinson <[email protected]>2023-12-20 01:53:27 -0800
commitaa6e04a5562052db172117043165ae999683b052 (patch)
tree11b36fabd9a542aca0f5ad234d365ce8067dd46d /common
parent59c466077fd6f16af64afcc6260bb61aa4e632dc (diff)
Ensure struct members are initialized
Diffstat (limited to 'common')
-rw-r--r--common/alsem.h2
-rw-r--r--common/polyphase_resampler.h2
2 files changed, 2 insertions, 2 deletions
diff --git a/common/alsem.h b/common/alsem.h
index 9f72d1c6..90b39319 100644
--- a/common/alsem.h
+++ b/common/alsem.h
@@ -24,7 +24,7 @@ class semaphore {
#else
using native_type = sem_t;
#endif
- native_type mSem;
+ native_type mSem{};
public:
semaphore(unsigned int initial=0);
diff --git a/common/polyphase_resampler.h b/common/polyphase_resampler.h
index 557485bb..764111c9 100644
--- a/common/polyphase_resampler.h
+++ b/common/polyphase_resampler.h
@@ -40,7 +40,7 @@ struct PPhaseResampler {
explicit operator bool() const noexcept { return !mF.empty(); }
private:
- uint mP, mQ, mM, mL;
+ uint mP{}, mQ{}, mM{}, mL{};
std::vector<double> mF;
};