From 860130783830fc39ea49a3c76f70ab79b4f31f92 Mon Sep 17 00:00:00 2001 From: Noel Grandin Date: Wed, 12 Aug 2015 15:09:36 +0200 Subject: loplugin: defaultparams Change-Id: Id0a933d3507bc0f8145afa04effadf8475c8e210 --- connectivity/source/drivers/file/FResultSet.cxx | 2 +- connectivity/source/drivers/firebird/PreparedStatement.cxx | 2 +- connectivity/source/drivers/flat/ETable.cxx | 14 +++++++------- .../source/drivers/postgresql/pq_databasemetadata.cxx | 2 +- .../source/drivers/postgresql/pq_resultsetmetadata.cxx | 2 +- connectivity/source/drivers/postgresql/pq_statement.cxx | 4 ++-- 6 files changed, 13 insertions(+), 13 deletions(-) (limited to 'connectivity') diff --git a/connectivity/source/drivers/file/FResultSet.cxx b/connectivity/source/drivers/file/FResultSet.cxx index 9f61747ca42d..6b7bac4b9bc9 100644 --- a/connectivity/source/drivers/file/FResultSet.cxx +++ b/connectivity/source/drivers/file/FResultSet.cxx @@ -1164,7 +1164,7 @@ void OResultSet::sortRows() m_pSortIndex = new OSortIndex(eKeyType,m_aOrderbyAscending); - while ( ExecuteRow( IResultSetHelper::NEXT, 1, false, true ) ) + while ( ExecuteRow( IResultSetHelper::NEXT, 1, false ) ) { m_aSelectRow->get()[0]->setValue( m_aRow->get()[0]->getValue() ); if ( m_pSQLAnalyzer->hasFunctions() ) diff --git a/connectivity/source/drivers/firebird/PreparedStatement.cxx b/connectivity/source/drivers/firebird/PreparedStatement.cxx index 3a783788f2ef..f5cfdeeca9c3 100644 --- a/connectivity/source/drivers/firebird/PreparedStatement.cxx +++ b/connectivity/source/drivers/firebird/PreparedStatement.cxx @@ -317,7 +317,7 @@ void SAL_CALL OPreparedStatement::setNull(sal_Int32 nIndex, sal_Int32 /*nSqlType checkDisposed(OStatementCommonBase_Base::rBHelper.bDisposed); ensurePrepared(); - setParameterNull(nIndex, true); + setParameterNull(nIndex); } void SAL_CALL OPreparedStatement::setBoolean(sal_Int32 /*nIndex*/, sal_Bool /*bValue*/) diff --git a/connectivity/source/drivers/flat/ETable.cxx b/connectivity/source/drivers/flat/ETable.cxx index 854ea2371773..fa80969e02c6 100644 --- a/connectivity/source/drivers/flat/ETable.cxx +++ b/connectivity/source/drivers/flat/ETable.cxx @@ -88,7 +88,7 @@ void OFlatTable::fillColumns(const ::com::sun::star::lang::Locale& _aLocale) QuotedTokenizedString aFirstLine; if(bRead) { - bRead = readLine(&rowPos.second, &rowPos.first, false); + bRead = readLine(&rowPos.second, &rowPos.first); if(bRead) setRowPos(rowNum++, rowPos); } @@ -98,7 +98,7 @@ void OFlatTable::fillColumns(const ::com::sun::star::lang::Locale& _aLocale) // use first non-empty row as headerline because we need the number of columns while(bRead && m_aCurrentLine.Len() == 0) { - bRead = readLine(&rowPos.second, &rowPos.first, false); + bRead = readLine(&rowPos.second, &rowPos.first); if(bRead) setRowPos(rowNum++, rowPos); } @@ -161,7 +161,7 @@ void OFlatTable::fillColumns(const ::com::sun::star::lang::Locale& _aLocale) } } ++nRowCount; - bRead = readLine(&rowPos.second, &rowPos.first, false); + bRead = readLine(&rowPos.second, &rowPos.first); if(bRead) setRowPos(rowNum++, rowPos); } @@ -208,7 +208,7 @@ void OFlatTable::impl_fillColumnInfo_nothrow(QuotedTokenizedString& aFirstLine, if ( bNumeric ) { // first without fielddelimiter - OUString aField = aFirstLine.GetTokenSpecial(nStartPosFirstLine,m_cFieldDelimiter,'\0'); + OUString aField = aFirstLine.GetTokenSpecial(nStartPosFirstLine,m_cFieldDelimiter); if (aField.isEmpty() || (m_cStringDelimiter && m_cStringDelimiter == aField[0])) { @@ -299,7 +299,7 @@ void OFlatTable::impl_fillColumnInfo_nothrow(QuotedTokenizedString& aFirstLine, } else if ( io_nType == DataType::DATE || io_nType == DataType::TIMESTAMP || io_nType == DataType::TIME) { - OUString aField = aFirstLine.GetTokenSpecial(nStartPosFirstLine,m_cFieldDelimiter,'\0'); + OUString aField = aFirstLine.GetTokenSpecial(nStartPosFirstLine,m_cFieldDelimiter); if (aField.isEmpty() || (m_cStringDelimiter && m_cStringDelimiter == aField[0])) { @@ -375,7 +375,7 @@ void OFlatTable::impl_fillColumnInfo_nothrow(QuotedTokenizedString& aFirstLine, } else { - OUString aField = aFirstLine.GetTokenSpecial(nStartPosFirstLine,m_cFieldDelimiter,'\0'); + OUString aField = aFirstLine.GetTokenSpecial(nStartPosFirstLine,m_cFieldDelimiter); if (aField.isEmpty() || (m_cStringDelimiter && m_cStringDelimiter == aField[0])) { @@ -776,7 +776,7 @@ bool OFlatTable::seekRow(IResultSetHelper::Movement eCursorPosition, sal_Int32 n m_pFileStream->Seek(m_nFilePos); TRowPositionInFile newRowPos; - if(!readLine(&newRowPos.second, &newRowPos.first, false)) + if(!readLine(&newRowPos.second, &newRowPos.first)) { m_nMaxRowCount = m_nRowPos - 1; return false; diff --git a/connectivity/source/drivers/postgresql/pq_databasemetadata.cxx b/connectivity/source/drivers/postgresql/pq_databasemetadata.cxx index 10186778d3c5..366fb61ebc46 100644 --- a/connectivity/source/drivers/postgresql/pq_databasemetadata.cxx +++ b/connectivity/source/drivers/postgresql/pq_databasemetadata.cxx @@ -1427,7 +1427,7 @@ static void columnMetaData2DatabaseTypeDescription( if( domains ) queryBuf.appendAscii( " OR " ); queryBuf.appendAscii( "oid = " ); - queryBuf.append( row->getInt(12 ), 10 ); + queryBuf.append( row->getInt(12 ) ); domains ++; } } diff --git a/connectivity/source/drivers/postgresql/pq_resultsetmetadata.cxx b/connectivity/source/drivers/postgresql/pq_resultsetmetadata.cxx index 61584a478e3c..461241c34ee7 100644 --- a/connectivity/source/drivers/postgresql/pq_resultsetmetadata.cxx +++ b/connectivity/source/drivers/postgresql/pq_resultsetmetadata.cxx @@ -168,7 +168,7 @@ void ResultSetMetaData::checkForTypes() buf.appendAscii( " OR " ); int oid = m_colDesc[i].typeOid; buf.appendAscii( "oid=" ); - buf.append( (sal_Int32) oid, 10 ); + buf.append( (sal_Int32) oid ); } Reference< XResultSet > rs = stmt->executeQuery( buf.makeStringAndClear() ); Reference< XRow > xRow( rs, UNO_QUERY ); diff --git a/connectivity/source/drivers/postgresql/pq_statement.cxx b/connectivity/source/drivers/postgresql/pq_statement.cxx index 87b33c6509d3..52eb1f29f272 100644 --- a/connectivity/source/drivers/postgresql/pq_statement.cxx +++ b/connectivity/source/drivers/postgresql/pq_statement.cxx @@ -480,7 +480,7 @@ bool executePostgresCommand( const OString & cmd, struct CommandData *data ) if( *(data->pLastOidInserted) ) { buf.append( ", usedOid=" ); - buf.append( *(data->pLastOidInserted) , 10 ); + buf.append( *(data->pLastOidInserted) ); buf.append( ", diagnosedTable=" ); buf.append( OUStringToOString( *data->pLastTableInserted, pSettings->encoding ) ); @@ -723,7 +723,7 @@ Reference< XResultSet > getGeneratedValuesFromLastInsert( else bufferQuoteIdentifier( buf, lastTableInserted, pConnectionSettings ); buf.append( " WHERE oid = " ); - buf.append( nLastOid , 10 ); + buf.append( nLastOid ); query = buf.makeStringAndClear(); } else if ( lastTableInserted.getLength() && lastQuery.getLength() ) -- cgit