summaryrefslogtreecommitdiffstats
path: root/core/downloadfromdcthread.cpp
diff options
context:
space:
mode:
authorGravatar Dirk Hohndel <dirk@hohndel.org>2017-12-27 22:02:12 -0800
committerGravatar Dirk Hohndel <dirk@hohndel.org>2017-12-27 22:02:12 -0800
commite8719413a7962f737938a59ce54637352fb282f4 (patch)
tree9d657e3f22f900512a492f484627dcdc099f2873 /core/downloadfromdcthread.cpp
parentdb434702be51e913e7757af14ed3808ebecb81e1 (diff)
downloadsubsurface-e8719413a7962f737938a59ce54637352fb282f4.tar.gz
Cleanup: avoid uninitialized members
This is basically to make Coverity happy. Coverity CID 208300 Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Diffstat (limited to 'core/downloadfromdcthread.cpp')
-rw-r--r--core/downloadfromdcthread.cpp10
1 files changed, 5 insertions, 5 deletions
diff --git a/core/downloadfromdcthread.cpp b/core/downloadfromdcthread.cpp
index 799610f80..ede307ce0 100644
--- a/core/downloadfromdcthread.cpp
+++ b/core/downloadfromdcthread.cpp
@@ -179,16 +179,16 @@ DCDeviceData *DCDeviceData::m_instance = NULL;
DCDeviceData::DCDeviceData(QObject *parent) : QObject(parent)
{
- if (m_instance) {
- qDebug() << "already have an instance of DCDevieData";
- return;
- }
- m_instance = this;
memset(&data, 0, sizeof(data));
data.trip = nullptr;
data.download_table = nullptr;
data.diveid = 0;
data.deviceid = 0;
+ if (m_instance) {
+ qDebug() << "already have an instance of DCDevieData";
+ return;
+ }
+ m_instance = this;
}
DCDeviceData *DCDeviceData::instance()