summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-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()