diff --git a/src/demod/DemodulatorPreThread.cpp b/src/demod/DemodulatorPreThread.cpp index a92d942..86bac7f 100644 --- a/src/demod/DemodulatorPreThread.cpp +++ b/src/demod/DemodulatorPreThread.cpp @@ -8,7 +8,7 @@ #include "DemodulatorPreThread.h" #include "CubicSDR.h" -DemodulatorPreThread::DemodulatorPreThread() : IOThread(), iqResampler(NULL), iqResampleRatio(1), iqInputQueue(NULL), iqOutputQueue(NULL), threadQueueNotify(NULL), commandQueue(NULL), cModem(nullptr), cModemKit(nullptr) +DemodulatorPreThread::DemodulatorPreThread() : IOThread(), iqResampler(NULL), iqResampleRatio(1), cModem(nullptr), cModemKit(nullptr), iqInputQueue(NULL), iqOutputQueue(NULL), threadQueueNotify(NULL), commandQueue(NULL) { initialized.store(false); diff --git a/src/demod/DemodulatorThread.cpp b/src/demod/DemodulatorThread.cpp index cd6d5d2..8047e5a 100644 --- a/src/demod/DemodulatorThread.cpp +++ b/src/demod/DemodulatorThread.cpp @@ -12,7 +12,7 @@ #include #endif -DemodulatorThread::DemodulatorThread(DemodulatorInstance *parent) : IOThread(), iqAutoGain(NULL), audioSampleRate(0), squelchLevel(0), signalLevel(0), squelchEnabled(false), iqInputQueue(NULL), audioOutputQueue(NULL), audioVisOutputQueue(NULL), threadQueueControl(NULL), threadQueueNotify(NULL), cModem(nullptr), cModemKit(nullptr) { +DemodulatorThread::DemodulatorThread(DemodulatorInstance *parent) : IOThread(), iqAutoGain(NULL), audioSampleRate(0), squelchLevel(0), signalLevel(0), squelchEnabled(false), cModem(nullptr), cModemKit(nullptr), iqInputQueue(NULL), audioOutputQueue(NULL), audioVisOutputQueue(NULL), threadQueueControl(NULL), threadQueueNotify(NULL) { demodInstance = parent; muted.store(false); diff --git a/src/process/FFTDataDistributor.cpp b/src/process/FFTDataDistributor.cpp index a2e10db..db121fe 100644 --- a/src/process/FFTDataDistributor.cpp +++ b/src/process/FFTDataDistributor.cpp @@ -1,6 +1,6 @@ #include "FFTDataDistributor.h" -FFTDataDistributor::FFTDataDistributor() : linesPerSecond(DEFAULT_WATERFALL_LPS), lineRateAccum(0.0), fftSize(DEFAULT_FFT_SIZE) { +FFTDataDistributor::FFTDataDistributor() : fftSize(DEFAULT_FFT_SIZE), linesPerSecond(DEFAULT_WATERFALL_LPS), lineRateAccum(0.0) { bufferedItems = 0; } diff --git a/src/util/DataTree.cpp b/src/util/DataTree.cpp index e150307..8fc1f85 100755 --- a/src/util/DataTree.cpp +++ b/src/util/DataTree.cpp @@ -33,7 +33,7 @@ using namespace std; #define STRINGIFY(A) #A -DataElement::DataElement() : data_type(DATA_NULL), data_val(NULL), data_size(0), unit_size(0) { +DataElement::DataElement() : data_type(DATA_NULL), data_size(0), unit_size(0), data_val(NULL) { } DataElement::~DataElement() { @@ -393,11 +393,11 @@ void DataElement::setSerialized(char *ser_str) { /* DataNode class */ -DataNode::DataNode(): ptr(0), parentNode(NULL) { +DataNode::DataNode(): parentNode(NULL), ptr(0) { data_elem = new DataElement(); } -DataNode::DataNode(const char *name_in): ptr(0), parentNode(NULL) { +DataNode::DataNode(const char *name_in): parentNode(NULL), ptr(0) { node_name = name_in; data_elem = new DataElement(); } @@ -1528,7 +1528,7 @@ bool DataTree::SaveToFileXML(const std::string& filename) { bool DataTree::SaveToFile(const std::string& filename, bool compress, int compress_level) { long dataSize, compressedSize, headerSize; - char *serialized, *hdr_serialized, *compressed; + char *serialized = nullptr, *hdr_serialized = nullptr, *compressed = nullptr; DataTree dtHeader; dataSize = getSerialized(&serialized); @@ -1580,7 +1580,10 @@ bool DataTree::SaveToFile(const std::string& filename, bool compress, int compre } bool DataTree::LoadFromFile(const std::string& filename) { - char *compressed, *serialized, *hdr_serialized; +#if USE_FASTLZ + char *compressed; +#endif + char *serialized, *hdr_serialized; long dataSize, headerSize, compressedSize; ifstream fin(filename.c_str(), ios::binary); diff --git a/src/visual/WaterfallCanvas.cpp b/src/visual/WaterfallCanvas.cpp index 2270fa3..ce4630e 100644 --- a/src/visual/WaterfallCanvas.cpp +++ b/src/visual/WaterfallCanvas.cpp @@ -36,7 +36,7 @@ wxEND_EVENT_TABLE() WaterfallCanvas::WaterfallCanvas(wxWindow *parent, int *attribList) : InteractiveCanvas(parent, attribList), dragState(WF_DRAG_NONE), nextDragState(WF_DRAG_NONE), fft_size(0), waterfall_lines(0), - dragOfs(0), mouseZoom(1), zoom(1), freqMove(0.0), freqMoving(false), hoverAlpha(1.0) { + dragOfs(0), mouseZoom(1), zoom(1), freqMoving(false), freqMove(0.0), hoverAlpha(1.0) { glContext = new PrimaryGLContext(this, &wxGetApp().GetContext(this)); linesPerSecond = 30;