Fix crash when network information backend is not available
This commit is contained in:
parent
0c15936119
commit
00d3a8198a
|
@ -282,7 +282,7 @@ void SyncthingConnection::handleMeteredConnection()
|
|||
{
|
||||
#ifdef SYNCTHINGCONNECTION_SUPPORT_METERED
|
||||
const auto *const networkInformation = QNetworkInformation::instance();
|
||||
if (!networkInformation->supports(QNetworkInformation::Feature::Metered)) {
|
||||
if (!networkInformation || !networkInformation->supports(QNetworkInformation::Feature::Metered)) {
|
||||
return;
|
||||
}
|
||||
if (networkInformation->isMetered() && m_pausingOnMeteredConnection) {
|
||||
|
|
Loading…
Reference in New Issue