diff options
author | Stephan Bergmann <sbergman@redhat.com> | 2021-12-22 09:16:38 +0100 |
---|---|---|
committer | Stephan Bergmann <sbergman@redhat.com> | 2021-12-22 13:33:46 +0100 |
commit | cd057f55bae74c6a14d893d292286909430b4382 (patch) | |
tree | 358ffe835c57a090d28186684c55a08487b0efea /vcl/win | |
parent | f22751cac9b81e5d7c5ad6b2e0a2eff21b683cad (diff) |
Silence loplugin:fakebool for BOOL GetMessageW even harder
8f22ce5ea3e62a4837773f6958b8ce7ac96f811a "loplugin:fakebool (clang-cl)" had
tried to use auto to silence the warning about GetMessageW's misused BOOL return
type (where GetMessageW encodes more than just true vs. false), but that no
longer works after Clang 14 trunk
<https://github.com/llvm/llvm-project/commit/c9e46219f38da5c3fbfe41012173dc893516826e>
"[clang] retain type sugar in auto / template argument deduction", so just use
int here as the type for which BOOL is a typedef according to
<https://docs.microsoft.com/en-us/openspecs/windows_protocols/ms-dtyp/9d81be47-232e-42cf-8f0d-7a3b29bf2eb2>
"BOOL".
Change-Id: Ie703676e858dba915de5c4496c02db82a2735e29
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/127298
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
Diffstat (limited to 'vcl/win')
-rw-r--r-- | vcl/win/dtrans/MtaOleClipb.cxx | 2 | ||||
-rw-r--r-- | vcl/win/dtrans/target.cxx | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/vcl/win/dtrans/MtaOleClipb.cxx b/vcl/win/dtrans/MtaOleClipb.cxx index c1caea416d13..4faba21367f2 100644 --- a/vcl/win/dtrans/MtaOleClipb.cxx +++ b/vcl/win/dtrans/MtaOleClipb.cxx @@ -660,7 +660,7 @@ unsigned int CMtaOleClipboard::run( ) for (;;) { MSG msg; - auto const bRet = GetMessageW(&msg, nullptr, 0, 0); + int const bRet = GetMessageW(&msg, nullptr, 0, 0); if (bRet == 0) { break; diff --git a/vcl/win/dtrans/target.cxx b/vcl/win/dtrans/target.cxx index a4ad523e34ee..fd4fb32a694a 100644 --- a/vcl/win/dtrans/target.cxx +++ b/vcl/win/dtrans/target.cxx @@ -210,7 +210,7 @@ DWORD WINAPI DndTargetOleSTAFunc(LPVOID pParams) // for a later call to AttachThreadInput for (;;) { - auto const bRet = GetMessageW(&msg, nullptr, 0, 0); + int const bRet = GetMessageW(&msg, nullptr, 0, 0); if (bRet == 0) { break; |