From 9af8f190ed1bf3f76897ad0c078db16451d6fb69 Mon Sep 17 00:00:00 2001 From: Stephan Bergmann Date: Mon, 22 Jan 2018 13:11:34 +0100 Subject: More loplugin:cstylecast on Windows Automatic rewrite (of loplugin:cstylecast and loplugin:unnecessaryparen) after cab0427cadddb3aaf1349c66f2fa13a4234ba4b2 "Enable loplugin:cstylecast for some more cases" and a409d32e7f6fc09e041079d6dbc3c927497adfed "More loplugin:cstylecast" Change-Id: Ib3355159dd08333e1b7a8d091caf2069cdcc7862 Reviewed-on: https://gerrit.libreoffice.org/48317 Tested-by: Jenkins Reviewed-by: Stephan Bergmann --- desktop/win32/source/guiloader/genericloader.cxx | 2 +- desktop/win32/source/officeloader/officeloader.cxx | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) (limited to 'desktop') diff --git a/desktop/win32/source/guiloader/genericloader.cxx b/desktop/win32/source/guiloader/genericloader.cxx index 8beb240c0316..193e74bd11b0 100644 --- a/desktop/win32/source/guiloader/genericloader.cxx +++ b/desktop/win32/source/guiloader/genericloader.cxx @@ -33,7 +33,7 @@ static int GenericMain() GetStartupInfoW( &aStartupInfo ); - DWORD dwExitCode = (DWORD)-1; + DWORD dwExitCode = DWORD(-1); PROCESS_INFORMATION aProcessInfo; diff --git a/desktop/win32/source/officeloader/officeloader.cxx b/desktop/win32/source/officeloader/officeloader.cxx index 45b94a8e128d..10393741b235 100644 --- a/desktop/win32/source/officeloader/officeloader.cxx +++ b/desktop/win32/source/officeloader/officeloader.cxx @@ -52,7 +52,7 @@ int WINAPI wWinMain( HINSTANCE, HINSTANCE, LPWSTR, int ) if ((aStartupInfo.dwFlags & STARTF_USESTDHANDLES) == 0) AttachConsole(ATTACH_PARENT_PROCESS); - DWORD dwExitCode = (DWORD)-1; + DWORD dwExitCode = DWORD(-1); BOOL fSuccess = FALSE; LPWSTR lpCommandLine = nullptr; @@ -129,7 +129,7 @@ int WINAPI wWinMain( HINSTANCE, HINSTANCE, LPWSTR, int ) LocalFree(argv2); } - if ( _ltow( (long)GetCurrentProcessId(),szParentProcessId, 10 ) && bHeadlessMode ) + if ( _ltow( static_cast(GetCurrentProcessId()),szParentProcessId, 10 ) && bHeadlessMode ) SetEnvironmentVariableW( L"ATTACHED_PARENT_PROCESSID", szParentProcessId ); PROCESS_INFORMATION aProcessInfo; -- cgit