mirror of
https://github.com/swift-project/pilotclient.git
synced 2026-04-30 05:51:23 +08:00
Use QRecursiveMutex
QMutex with QMutex::Recursive is deprecated
This commit is contained in:
@@ -169,7 +169,7 @@ namespace BlackMisc
|
||||
void sessionValue(const QString &key);
|
||||
|
||||
private:
|
||||
mutable QMutex m_mutex { QMutex::Recursive };
|
||||
mutable QRecursiveMutex m_mutex;
|
||||
bool m_updateInProgress = false;
|
||||
bool m_found = false;
|
||||
bool m_pendingRead = false;
|
||||
|
||||
@@ -90,7 +90,7 @@ namespace BlackMisc
|
||||
CIdentifier m_identifier = CIdentifier::anonymous();
|
||||
|
||||
QMap<QString, Channel> m_channels;
|
||||
mutable QMutex m_channelsMutex { QMutex::Recursive };
|
||||
mutable QRecursiveMutex m_channelsMutex;
|
||||
};
|
||||
}
|
||||
}
|
||||
|
||||
@@ -54,7 +54,7 @@ namespace BlackMisc::SharedState
|
||||
Channel &getChannel(const QObject *object);
|
||||
|
||||
QMap<QString, Channel> m_channels;
|
||||
mutable QMutex m_channelsMutex { QMutex::Recursive };
|
||||
mutable QRecursiveMutex m_channelsMutex;
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
@@ -299,7 +299,7 @@ namespace BlackMisc
|
||||
void markAllAsSaved(const QStringList &keys);
|
||||
|
||||
//! Mutex protecting operations which are critical on m_elements.
|
||||
mutable QMutex m_mutex { QMutex::Recursive };
|
||||
mutable QRecursiveMutex m_mutex;
|
||||
|
||||
protected:
|
||||
//! Synchronously return a current value.
|
||||
|
||||
@@ -184,7 +184,7 @@ namespace BlackMisc
|
||||
|
||||
bool m_started = false;
|
||||
bool m_finished = false;
|
||||
mutable QMutex m_finishedMutex { QMutex::Recursive };
|
||||
mutable QRecursiveMutex m_finishedMutex;
|
||||
static QSet<CWorkerBase *> s_allWorkers;
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user