User: hr Date: 06/06/19 18:40:06 Modified: /dba/connectivity/source/drivers/kab/ KStatement.cxx
Log: INTEGRATION: CWS warnings01 (1.2.28); FILE MERGED 2006/01/30 14:18:54 sb 1.2.28.1: #i53898# Made code warning-free. File Changes: Directory: /dba/connectivity/source/drivers/kab/ ================================================ File [changed]: KStatement.cxx Url: http://dba.openoffice.org/source/browse/dba/connectivity/source/drivers/kab/KStatement.cxx?r1=1.2&r2=1.3 Delta lines: +26 -14 --------------------- --- KStatement.cxx 19 Dec 2005 16:51:20 -0000 1.2 +++ KStatement.cxx 20 Jun 2006 01:40:03 -0000 1.3 @@ -81,11 +81,11 @@ KabCommonStatement::KabCommonStatement(KabConnection* _pConnection ) : KabCommonStatement_BASE(m_aMutex), OPropertySetHelper(KabCommonStatement_BASE::rBHelper), - rBHelper(KabCommonStatement_BASE::rBHelper), - m_pParseTree(NULL), - m_aSQLIterator(_pConnection->createCatalog()->getTables(), _pConnection->getMetaData(), NULL), m_aParser(_pConnection->getDriver()->getMSFactory()), - m_pConnection(_pConnection) + m_aSQLIterator(_pConnection->createCatalog()->getTables(), _pConnection->getMetaData(), NULL), + m_pParseTree(NULL), + m_pConnection(_pConnection), + rBHelper(KabCommonStatement_BASE::rBHelper) { m_pConnection->acquire(); } @@ -121,6 +121,9 @@ // WHERE 0 <> 1 // (might not be correct SQL... don't care, handling anyway) return new KabConditionConstant(pLeft->getTokenValue() != pRight->getTokenValue()); + + default: + break; } } else if (SQL_ISRULE(pLeft, column_ref) && pRight->isToken()) @@ -141,6 +144,9 @@ case SQL_NODE_NOTEQUAL: // WHERE Name <> 'Jones' return new KabConditionDifferent(sColumnName, sMatchString); + + default: + break; } } } @@ -214,6 +220,9 @@ ::dbtools::throwGenericSQLException( ::rtl::OUString::createFromAscii("Syntax error or keyword not recognized."), NULL); + // Unreachable: + OSL_ASSERT(false); + return 0; } // ----------------------------------------------------------------------------- KabOrder *KabCommonStatement::analyseOrderByClause(const OSQLParseNode *pParseNode) const throw(SQLException) @@ -261,6 +270,9 @@ ::dbtools::throwGenericSQLException( ::rtl::OUString::createFromAscii("Syntax error or keyword not recognized."), NULL); + // Unreachable: + OSL_ASSERT(false); + return 0; } //------------------------------------------------------------------------------ sal_Bool KabCommonStatement::isTableKnown(KabResultSet *pResult) const @@ -433,7 +445,7 @@ return (Reference< XConnection >) m_pConnection; } // ------------------------------------------------------------------------- -sal_Int32 SAL_CALL KabCommonStatement::executeUpdate( const ::rtl::OUString& sql ) throw(SQLException, RuntimeException) +sal_Int32 SAL_CALL KabCommonStatement::executeUpdate( const ::rtl::OUString& ) throw(SQLException, RuntimeException) { ::osl::MutexGuard aGuard( m_aMutex ); checkDisposed(KabCommonStatement_BASE::rBHelper.bDisposed); @@ -485,10 +497,10 @@ } // ------------------------------------------------------------------------- sal_Bool KabCommonStatement::convertFastPropertyValue( - Any & rConvertedValue, - Any & rOldValue, - sal_Int32 nHandle, - const Any& rValue) throw (::com::sun::star::lang::IllegalArgumentException) + Any &, + Any &, + sal_Int32, + const Any&) throw (::com::sun::star::lang::IllegalArgumentException) { sal_Bool bConverted = sal_False; // here we have to try to convert @@ -496,7 +508,7 @@ return bConverted; } // ------------------------------------------------------------------------- -void KabCommonStatement::setFastPropertyValue_NoBroadcast(sal_Int32 nHandle,const Any& rValue) throw (Exception) +void KabCommonStatement::setFastPropertyValue_NoBroadcast(sal_Int32 nHandle,const Any&) throw (Exception) { // set the value to whatever is nescessary switch (nHandle) @@ -517,7 +529,7 @@ OSL_ENSURE(false, "KabCommonStatement::setFastPropertyValue_NoBroadcast is not implemented!"); } // ------------------------------------------------------------------------- -void KabCommonStatement::getFastPropertyValue(Any& rValue,sal_Int32 nHandle) const +void KabCommonStatement::getFastPropertyValue(Any&,sal_Int32 nHandle) const { switch (nHandle) { --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
