#include <QThread>

class MyThread : public QThread
{
public:
    static void mySleep(unsigned long secs) { sleep(secs); } // sleep() is protected in Qt 4.
};

int main()
{
    MyThread::mySleep(60);
}

#include <QThread>

int main()
{
    QThread::sleep(60);
}

--- 
+++ 
@@ -1,6 +1,12 @@
 #include <QThread>
+
+class MyThread : public QThread
+{
+public:
+    static void mySleep(unsigned long secs) { sleep(secs); } // sleep() is protected in Qt 4.
+};
 
 int main()
 {
-    QThread::sleep(60);
+    MyThread::mySleep(60);
 }
Fix "inifiniteLoop" test for Qt 4.

QThread::sleep() is protected there.

Change-Id: If7b6dbabd594c0a0eaf4ea2b7c691c7e9c00c55a
Reviewed-by: Christian Stenger <accbb51712d7b9c4fb108439d01e716148e5f9e6@digia.com>
