mirror of
https://github.com/Cockatrice/Cockatrice.git
synced 2025-12-22 23:26:14 -08:00
removed usleep() call to enable compilation on Windows again
This commit is contained in:
@@ -64,8 +64,15 @@ void Server::prepareDestroy()
|
|||||||
clientsLock.unlock();
|
clientsLock.unlock();
|
||||||
|
|
||||||
bool done = false;
|
bool done = false;
|
||||||
|
|
||||||
|
class SleeperThread : public QThread
|
||||||
|
{
|
||||||
|
public:
|
||||||
|
static void msleep(unsigned long msecs) { QThread::usleep(msecs); }
|
||||||
|
};
|
||||||
|
|
||||||
do {
|
do {
|
||||||
usleep(10000);
|
SleeperThread::msleep(10);
|
||||||
clientsLock.lockForRead();
|
clientsLock.lockForRead();
|
||||||
if (clients.isEmpty())
|
if (clients.isEmpty())
|
||||||
done = true;
|
done = true;
|
||||||
|
|||||||
Reference in New Issue
Block a user