Browse Source

weather : Initialize saved coordinates

Initialize the saved latitude and longitude so Weather instances start with
defined coordinates before periodic updates use them.

Found by Coverity (UNINIT_CTOR).

Signed-off-by: Robin Getz <rgetz503@gmail.com>
chirpmodem-v8.0.0
Robin Getz 2 months ago
parent
commit
3cbe1e5662
No known key found for this signature in database
GPG Key ID: 51C7231FFED0E060
  1. 4
      sdrbase/util/weather.cpp

4
sdrbase/util/weather.cpp

@ -25,7 +25,9 @@ @@ -25,7 +25,9 @@
#include <QJsonDocument>
#include <QJsonObject>
Weather::Weather()
Weather::Weather() :
m_latitude(0.0f),
m_longitude(0.0f)
{
connect(&m_timer, &QTimer::timeout, this, &Weather::update);
}

Loading…
Cancel
Save