ProcessReaper: Simplify takeReaperSetupList()

Change-Id: I1904a8e94ebee608e2fdffd888799a45399ac4a2
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
This commit is contained in:
Jarek Kobus
2023-10-23 23:10:30 +02:00
parent a724bd40f5
commit 7faec2f469

View File

@@ -167,9 +167,7 @@ private:
QList<ReaperSetup> takeReaperSetupList() QList<ReaperSetup> takeReaperSetupList()
{ {
QMutexLocker locker(&m_mutex); QMutexLocker locker(&m_mutex);
const QList<ReaperSetup> reaperSetupList = m_reaperSetupList; return std::exchange(m_reaperSetupList, {});
m_reaperSetupList.clear();
return reaperSetupList;
} }
void flush() void flush()