From 6257ca589f435ea9b4f73067098ab54bbc873faf Mon Sep 17 00:00:00 2001 From: Kai Koehne Date: Fri, 5 Apr 2019 15:22:08 +0200 Subject: Fix clang-cl errors about narrowing conversions Force value to be a DWORD (unsigned long) instead of HRESULT (signed long). Fixes bluetoothsocket_winrt.cpp(770,10): error: case value evaluates to 2147952460, which cannot be narrowed to type 'long' [-Wc++11-narrowing] Change-Id: I4f1eb75807d4783b835094ad1b33e56f601ffb39 Reviewed-by: Alex Blasche Reviewed-by: Oliver Wolff --- src/bluetooth/qbluetoothsocket_winrt.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/bluetooth/qbluetoothsocket_winrt.cpp b/src/bluetooth/qbluetoothsocket_winrt.cpp index 79dccdd6..a4af8f72 100644 --- a/src/bluetooth/qbluetoothsocket_winrt.cpp +++ b/src/bluetooth/qbluetoothsocket_winrt.cpp @@ -765,7 +765,7 @@ HRESULT QBluetoothSocketPrivateWinRT::handleConnectOpFinished(ABI::Windows::Foun return S_OK; } - HRESULT hr = action->GetResults(); + DWORD hr = action->GetResults(); switch (hr) { case 0x8007274c: // A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond. errorString = QBluetoothSocket::tr("Connection timed out"); -- cgit v1.2.3