summaryrefslogtreecommitdiffstats
path: root/src/corelib/thread
diff options
context:
space:
mode:
authorThiago Macieira <thiago.macieira@intel.com>2018-09-20 06:57:54 -0500
committerThiago Macieira <thiago.macieira@intel.com>2018-09-25 22:14:10 +0000
commite3e28915c300cef0e997345e1bd74610fc70287f (patch)
treed47068dc846ae3248ba1c71977b6a8b0b9562592 /src/corelib/thread
parent7e1a0c07390ed18de074ce5450b272838a3b8ac8 (diff)
Fix erroneous use of errno with qErrnoWarning
On Windows, the error code to be used with qErrnoWarning is not errno, but Windows's GetLastError(). Obviously, right? So don't pass errno to it, just let it get the error message straight from qt_error_string(), which will use GetLastError(). Change-Id: I44e7d800c68141bdaae0fffd155619c93e3f3dab Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
Diffstat (limited to 'src/corelib/thread')
-rw-r--r--src/corelib/thread/qthread_win.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/corelib/thread/qthread_win.cpp b/src/corelib/thread/qthread_win.cpp
index caf51722cd..eebaf90d9b 100644
--- a/src/corelib/thread/qthread_win.cpp
+++ b/src/corelib/thread/qthread_win.cpp
@@ -511,7 +511,7 @@ void QThread::start(Priority priority)
#endif // Q_OS_WINRT
if (!d->handle) {
- qErrnoWarning(errno, "QThread::start: Failed to create thread");
+ qErrnoWarning("QThread::start: Failed to create thread");
d->running = false;
d->finished = true;
return;