diff options
author | Oliver Wolff <oliver.wolff@theqtcompany.com> | 2015-05-12 15:06:53 +0200 |
---|---|---|
committer | Kai Koehne <kai.koehne@theqtcompany.com> | 2015-05-18 08:59:55 +0000 |
commit | f65c04b37e63526540f9717a63fd305f4c3ac579 (patch) | |
tree | aea1cf9118e7df6350fa7407879a9420412e9edc /src/corelib | |
parent | 31e055cee97b5d41ff0bed3246b5e85a8d954164 (diff) |
WinRT/Winphone: Fix warnings in qtbase
Change-Id: I41725bcfeee0124b259e96f1e3a261e30f14350a
Reviewed-by: Kai Koehne <kai.koehne@theqtcompany.com>
Reviewed-by: Maurice Kalinowski <maurice.kalinowski@theqtcompany.com>
Diffstat (limited to 'src/corelib')
-rw-r--r-- | src/corelib/codecs/qwindowscodec.cpp | 2 | ||||
-rw-r--r-- | src/corelib/io/qlockfile_win.cpp | 6 | ||||
-rw-r--r-- | src/corelib/kernel/qeventdispatcher_winrt.cpp | 3 |
3 files changed, 8 insertions, 3 deletions
diff --git a/src/corelib/codecs/qwindowscodec.cpp b/src/corelib/codecs/qwindowscodec.cpp index cf427c64b6..0f8c5e1a4e 100644 --- a/src/corelib/codecs/qwindowscodec.cpp +++ b/src/corelib/codecs/qwindowscodec.cpp @@ -172,7 +172,7 @@ QString QWindowsLocalCodec::convertToUnicodeCharByChar(const char *chars, int le } #else QString s; - int size = mbstowcs(NULL, mb, length); + size_t size = mbstowcs(NULL, mb, length); if (size < 0) { Q_ASSERT("Error in CE TextCodec"); return QString(); diff --git a/src/corelib/io/qlockfile_win.cpp b/src/corelib/io/qlockfile_win.cpp index 27a63e126a..4e0d8134ec 100644 --- a/src/corelib/io/qlockfile_win.cpp +++ b/src/corelib/io/qlockfile_win.cpp @@ -142,7 +142,11 @@ bool QLockFilePrivate::isApparentlyStale() const return true; } } -#endif // !Q_OS_WINRT +#else // !Q_OS_WINRT + Q_UNUSED(pid); + Q_UNUSED(hostname); + Q_UNUSED(appname); +#endif // Q_OS_WINRT const qint64 age = QFileInfo(fileName).lastModified().msecsTo(QDateTime::currentDateTime()); return staleLockTime > 0 && age > staleLockTime; } diff --git a/src/corelib/kernel/qeventdispatcher_winrt.cpp b/src/corelib/kernel/qeventdispatcher_winrt.cpp index cc8e961be1..b5cfccd649 100644 --- a/src/corelib/kernel/qeventdispatcher_winrt.cpp +++ b/src/corelib/kernel/qeventdispatcher_winrt.cpp @@ -484,7 +484,8 @@ bool QEventDispatcherWinRT::event(QEvent *e) QEventDispatcherWinRTPrivate::QEventDispatcherWinRTPrivate() { CoInitializeEx(NULL, COINIT_APARTMENTTHREADED); - HRESULT hr = GetActivationFactory(HString::MakeReference(RuntimeClass_Windows_System_Threading_ThreadPoolTimer).Get(), &timerFactory); + HRESULT hr; + hr = GetActivationFactory(HString::MakeReference(RuntimeClass_Windows_System_Threading_ThreadPoolTimer).Get(), &timerFactory); Q_ASSERT_SUCCEEDED(hr); HANDLE interruptHandle = CreateEventEx(NULL, NULL, NULL, SYNCHRONIZE|EVENT_MODIFY_STATE); timerIdToHandle.insert(INTERRUPT_HANDLE, interruptHandle); |