From 09598dec333c0a060250a6ae394cba5ecd1f055a Mon Sep 17 00:00:00 2001 From: mrexodia Date: Fri, 31 Mar 2017 02:15:38 +0200 Subject: [PATCH] replace sleep with QThread::sleep (issue #20) --- src/mainwindow.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/mainwindow.cpp b/src/mainwindow.cpp index 88bf2caa..b5cac6b5 100644 --- a/src/mainwindow.cpp +++ b/src/mainwindow.cpp @@ -244,7 +244,7 @@ void MainWindow::start_web_server() { // Start web server thread.core = core; thread.start(); - sleep (1); + QThread::sleep (1); if (core->core->http_up == R_FALSE) { eprintf ("FAILED TO LAUNCH\n"); } @@ -834,7 +834,7 @@ void MainWindow::on_actionStart_Web_Server_triggered() // Start web server thread.core = core; thread.start(); - sleep (1); + QThread::sleep (1); if (core->core->http_up==R_FALSE) { eprintf ("FAILED TO LAUNCH\n"); }