summaryrefslogtreecommitdiffstats
path: root/backend/net/NetWorker.cpp
blob: 1eef13d937a924c4d0cb31926c41688e013f95da (plain)
1
2
3
4
5
6
7
8
9
10
11
12
#include "NetWorker.h"
#include <QThreadStorage>

NetWorker& NetWorker::spawn()
{
	static QThreadStorage<NetWorker *> storage;
	if (!storage.hasLocalData())
	{
		storage.setLocalData(new NetWorker());
	}
	return *storage.localData();
}