diff options
author | Stephan Bergmann <sbergman@redhat.com> | 2017-07-05 10:11:05 +0200 |
---|---|---|
committer | Stephan Bergmann <sbergman@redhat.com> | 2017-07-05 10:11:05 +0200 |
commit | d57c6ff67423151b8d79b5c21c118a22f2813115 (patch) | |
tree | 0999d04d61d0ffd2dbd9ffcd63f7014444d5d9ab | |
parent | 0153c51bb8530a34d665932e52ffd47064376c83 (diff) |
loplugin:casttovoid (clang-cl): connectivity
Change-Id: I68eef2cff5fffe61bd1ca2abc6d8ef42810406cb
-rw-r--r-- | connectivity/source/drivers/ado/AKeys.cxx | 8 | ||||
-rw-r--r-- | connectivity/source/drivers/ado/APreparedStatement.cxx | 10 | ||||
-rw-r--r-- | connectivity/source/drivers/ado/AStatement.cxx | 3 | ||||
-rw-r--r-- | connectivity/source/drivers/ado/Awrapado.cxx | 31 |
4 files changed, 12 insertions, 40 deletions
diff --git a/connectivity/source/drivers/ado/AKeys.cxx b/connectivity/source/drivers/ado/AKeys.cxx index 150933368f87..63a45cc6d31f 100644 --- a/connectivity/source/drivers/ado/AKeys.cxx +++ b/connectivity/source/drivers/ado/AKeys.cxx @@ -66,13 +66,7 @@ sdbcx::ObjectType OKeys::appendObject( const OUString&, const Reference< XProper OLEVariant vOptional; vOptional.setNoArg(); -#if OSL_DEBUG_LEVEL > 0 - KeyTypeEnum eKey = -#endif - OAdoKey::Map2KeyRule(getINT32(descriptor->getPropertyValue(OMetaConnection::getPropMap().getNameByIndex(PROPERTY_ID_TYPE)))); -#if OSL_DEBUG_LEVEL > 0 - (void)eKey; -#endif + OAdoKey::Map2KeyRule(getINT32(descriptor->getPropertyValue(OMetaConnection::getPropMap().getNameByIndex(PROPERTY_ID_TYPE)))); WpADOKey aKey = pKey->getImpl(); OUString sName = aKey.get_Name(); diff --git a/connectivity/source/drivers/ado/APreparedStatement.cxx b/connectivity/source/drivers/ado/APreparedStatement.cxx index 97f2f615deb0..4d8206a93508 100644 --- a/connectivity/source/drivers/ado/APreparedStatement.cxx +++ b/connectivity/source/drivers/ado/APreparedStatement.cxx @@ -197,16 +197,6 @@ void OPreparedStatement::setParameter(sal_Int32 parameterIndex, const DataTypeEn if(pParam) { m_pParameters->Append(pParam); -#if OSL_DEBUG_LEVEL > 0 - pParam = nullptr; - m_pParameters->get_Item(OLEVariant(sal_Int32(parameterIndex-1)),&pParam); - WpADOParameter aParam(pParam); - if(pParam) - { - DataTypeEnum eType = aParam.GetADOType(); - (void)eType; - } -#endif } } else diff --git a/connectivity/source/drivers/ado/AStatement.cxx b/connectivity/source/drivers/ado/AStatement.cxx index 3e8d0f5d2e3b..c7348fde31fd 100644 --- a/connectivity/source/drivers/ado/AStatement.cxx +++ b/connectivity/source/drivers/ado/AStatement.cxx @@ -724,11 +724,10 @@ sal_Bool OStatement_Base::convertFastPropertyValue( break; } } - catch( const Exception& e ) + catch( const Exception& ) { bModified = true; // will ensure that the property is set OSL_FAIL( "OStatement_Base::convertFastPropertyValue: caught something strange!" ); - (void)e; } return bModified; } diff --git a/connectivity/source/drivers/ado/Awrapado.cxx b/connectivity/source/drivers/ado/Awrapado.cxx index 34e5ea8a9692..53275c04a7a0 100644 --- a/connectivity/source/drivers/ado/Awrapado.cxx +++ b/connectivity/source/drivers/ado/Awrapado.cxx @@ -513,8 +513,7 @@ void WpADOField::get_Value(OLEVariant& aValVar) const { assert(pInterface); aValVar.setEmpty(); - bool bOk = SUCCEEDED(pInterface->get_Value(&aValVar)); - (void)bOk; + pInterface->get_Value(&aValVar); } OLEVariant WpADOField::get_Value() const @@ -1038,15 +1037,13 @@ void WpADOColumn::put_Name(const OUString& _rName) { assert(pInterface); OLEString bstr(_rName); - bool bErg = SUCCEEDED(pInterface->put_Name(bstr.asBSTR())); - (void)bErg; + pInterface->put_Name(bstr.asBSTR()); } void WpADOColumn::put_RelatedColumn(const OUString& _rName) { assert(pInterface); OLEString bstr(_rName); - bool bErg = SUCCEEDED(pInterface->put_RelatedColumn(bstr.asBSTR())); - (void)bErg; + pInterface->put_RelatedColumn(bstr.asBSTR()); } DataTypeEnum WpADOColumn::get_Type() const @@ -1149,8 +1146,7 @@ void WpADOKey::put_Name(const OUString& _rName) { assert(pInterface); OLEString bstr(_rName); - bool bErg = SUCCEEDED(pInterface->put_Name(bstr.asBSTR())); - (void)bErg; + pInterface->put_Name(bstr.asBSTR()); } KeyTypeEnum WpADOKey::get_Type() const @@ -1179,8 +1175,7 @@ void WpADOKey::put_RelatedTable(const OUString& _rName) { assert(pInterface); OLEString bstr(_rName); - bool bErg = SUCCEEDED(pInterface->put_RelatedTable(bstr.asBSTR())); - (void)bErg; + pInterface->put_RelatedTable(bstr.asBSTR()); } RuleEnum WpADOKey::get_DeleteRule() const @@ -1233,8 +1228,7 @@ void WpADOIndex::put_Name(const OUString& _rName) { assert(pInterface); OLEString bstr(_rName); - bool bErg = SUCCEEDED(pInterface->put_Name(bstr.asBSTR())); - (void)bErg; + pInterface->put_Name(bstr.asBSTR()); } bool WpADOIndex::get_Clustered() const @@ -1355,8 +1349,7 @@ void WpADOTable::put_Name(const OUString& _rName) { assert(pInterface); OLEString bstr(_rName); - bool bErg = SUCCEEDED(pInterface->put_Name(bstr.asBSTR())); - (void)bErg; + pInterface->put_Name(bstr.asBSTR()); } OUString WpADOTable::get_Type() const @@ -1447,8 +1440,7 @@ OUString WpADOGroup::get_Name() const void WpADOGroup::put_Name(const OUString& _rName) { OLEString bstr(_rName); - bool bErg = SUCCEEDED(pInterface->put_Name(bstr.asBSTR())); - (void)bErg; + pInterface->put_Name(bstr.asBSTR()); } RightsEnum WpADOGroup::GetPermissions( @@ -1492,8 +1484,7 @@ OUString WpADOUser::get_Name() const void WpADOUser::put_Name(const OUString& _rName) { OLEString bstr(_rName); - bool bErg = SUCCEEDED(pInterface->put_Name(bstr.asBSTR())); - (void)bErg; + pInterface->put_Name(bstr.asBSTR()); } bool WpADOUser::ChangePassword(const OUString& _rPwd,const OUString& _rNewPwd) @@ -1543,9 +1534,7 @@ WpBase::WpBase(IDispatch* pInt) { if (pIUnknown) { - ULONG nCount = pIUnknown->AddRef(); - (void)nCount; - // OSL_ENSURE(nCount == 1,"Count is greater than 1"); + pIUnknown->AddRef(); } } |