diff options
-rw-r--r-- | dtrans/test/win32/dnd/dndTest.cxx | 3 | ||||
-rw-r--r-- | onlineupdate/source/update/updater/progressui_win.cxx | 3 | ||||
-rw-r--r-- | registry/source/regimpl.cxx | 6 | ||||
-rw-r--r-- | sal/qa/rtl/locale/rtl_locale.cxx | 3 | ||||
-rw-r--r-- | sal/workben/testfile.cxx | 4 | ||||
-rw-r--r-- | shell/source/win32/simplemail/smplmailclient.cxx | 3 |
6 files changed, 7 insertions, 15 deletions
diff --git a/dtrans/test/win32/dnd/dndTest.cxx b/dtrans/test/win32/dnd/dndTest.cxx index d0261324a89b..aae5851c1cab 100644 --- a/dtrans/test/win32/dnd/dndTest.cxx +++ b/dtrans/test/win32/dnd/dndTest.cxx @@ -122,8 +122,7 @@ HRESULT doTest() extern Reference<XMultiServiceFactory> MultiServiceFactory; DWORD WINAPI MTAFunc( void* threadData) { - HRESULT hr= S_OK; - hr= CoInitializeEx( NULL, COINIT_MULTITHREADED); + HRESULT hr= CoInitializeEx( NULL, COINIT_MULTITHREADED); ATLASSERT( FAILED(hr) ); MSG msg; // force the creation of a message queue diff --git a/onlineupdate/source/update/updater/progressui_win.cxx b/onlineupdate/source/update/updater/progressui_win.cxx index 3cbbc6b9891d..49ae81e68d07 100644 --- a/onlineupdate/source/update/updater/progressui_win.cxx +++ b/onlineupdate/source/update/updater/progressui_win.cxx @@ -284,8 +284,7 @@ ShowProgressUI(bool indeterminate, bool initUIStrings) actx.lpSource = appPath; actx.lpResourceName = MAKEINTRESOURCE(IDR_COMCTL32_MANIFEST); - HANDLE hactx = INVALID_HANDLE_VALUE; - hactx = CreateActCtxW(&actx); + HANDLE hactx = CreateActCtxW(&actx); ULONG_PTR actxCookie = NULL; if (hactx != INVALID_HANDLE_VALUE) { // Push the specified activation context to the top of the activation stack. diff --git a/registry/source/regimpl.cxx b/registry/source/regimpl.cxx index 3499a5a83167..92a4187c8a5d 100644 --- a/registry/source/regimpl.cxx +++ b/registry/source/regimpl.cxx @@ -904,11 +904,10 @@ RegError ORegistry::deleteSubkeysAndValues(ORegKey* pKey) RegError ORegistry::loadKey(RegKeyHandle hKey, const OUString& regFileName, bool bWarnings, bool bReport) { - RegError _ret = RegError::NO_ERROR; ORegKey* pKey = static_cast< ORegKey* >(hKey); std::unique_ptr< ORegistry > pReg (new ORegistry()); - _ret = pReg->initRegistry(regFileName, RegAccessMode::READONLY); + RegError _ret = pReg->initRegistry(regFileName, RegAccessMode::READONLY); if (_ret != RegError::NO_ERROR) return _ret; ORegKey* pRootKey = pReg->getRootKey(); @@ -952,11 +951,10 @@ RegError ORegistry::loadKey(RegKeyHandle hKey, const OUString& regFileName, RegError ORegistry::saveKey(RegKeyHandle hKey, const OUString& regFileName, bool bWarnings, bool bReport) { - RegError _ret = RegError::NO_ERROR; ORegKey* pKey = static_cast< ORegKey* >(hKey); std::unique_ptr< ORegistry > pReg (new ORegistry()); - _ret = pReg->initRegistry(regFileName, RegAccessMode::READWRITE, true/*bCreate*/); + RegError _ret = pReg->initRegistry(regFileName, RegAccessMode::READWRITE, true/*bCreate*/); if (_ret != RegError::NO_ERROR) return _ret; ORegKey* pRootKey = pReg->getRootKey(); diff --git a/sal/qa/rtl/locale/rtl_locale.cxx b/sal/qa/rtl/locale/rtl_locale.cxx index ef8d7e31a656..f2b03fefebd1 100644 --- a/sal/qa/rtl/locale/rtl_locale.cxx +++ b/sal/qa/rtl/locale/rtl_locale.cxx @@ -269,8 +269,7 @@ public: rtl_Locale* pData1 = rtl_locale_register(rtl::OUString("en").getStr(), rtl::OUString("US").getStr(), rtl::OUString().getStr()); rtl_Locale* pData2 = rtl_locale_register(rtl::OUString("en").getStr(), rtl::OUString("US").getStr(), rtl::OUString().getStr()); - bool bLocaleAreEqual = false; - bLocaleAreEqual = (pData1 == pData2); + bool bLocaleAreEqual = (pData1 == pData2); CPPUNIT_ASSERT_MESSAGE("check operator ==()", bLocaleAreEqual); } diff --git a/sal/workben/testfile.cxx b/sal/workben/testfile.cxx index addb1b6b8603..dd9448bce907 100644 --- a/sal/workben/testfile.cxx +++ b/sal/workben/testfile.cxx @@ -2455,10 +2455,8 @@ void print_error( const ::rtl::OString& str, FileBase::RC rc ) int MAIN( int argc, char* argv[] ) { - sal_Bool fSuccess=sal_False; - //Initialization - fSuccess=Initialize(); + sal_Bool fSuccess=Initialize(); if ( !fSuccess ) { printf("Error during Initialization"); diff --git a/shell/source/win32/simplemail/smplmailclient.cxx b/shell/source/win32/simplemail/smplmailclient.cxx index d7504c5b6bee..359cc25ea9a1 100644 --- a/shell/source/win32/simplemail/smplmailclient.cxx +++ b/shell/source/win32/simplemail/smplmailclient.cxx @@ -125,12 +125,11 @@ namespace /* private */ return false; oslProcess proc; - oslProcessError err = osl_Process_E_Unknown; /* for efficiency reasons we are using a 'bad' cast here as a vector or OUStrings is nothing else than an array of pointers to rtl_uString's */ - err = osl_executeProcess( + oslProcessError err = osl_executeProcess( senddocUrl.pData, (rtl_uString**)&rCommandArgs[0], rCommandArgs.size(), |