diff options
author | Dirk Hohndel <dirk@hohndel.org> | 2017-12-27 22:02:12 -0800 |
---|---|---|
committer | Dirk Hohndel <dirk@hohndel.org> | 2017-12-27 22:02:12 -0800 |
commit | e8719413a7962f737938a59ce54637352fb282f4 (patch) | |
tree | 9d657e3f22f900512a492f484627dcdc099f2873 /core/downloadfromdcthread.cpp | |
parent | db434702be51e913e7757af14ed3808ebecb81e1 (diff) | |
download | subsurface-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.cpp | 10 |
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() |