diff options
author | Caolán McNamara <caolanm@redhat.com> | 2011-04-13 09:47:24 +0100 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2011-04-13 09:47:24 +0100 |
commit | 9d71fa66665fd841b1be18901c49359a454b0448 (patch) | |
tree | 0d7c5b3bdfe3c77ffa8a9043c38e2a1de9323af8 /connectivity/source/drivers/dbase | |
parent | 2d954b614956c70d02761060dbb465d809c74fc0 (diff) |
catch by const reference
Diffstat (limited to 'connectivity/source/drivers/dbase')
-rw-r--r-- | connectivity/source/drivers/dbase/DTable.cxx | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/connectivity/source/drivers/dbase/DTable.cxx b/connectivity/source/drivers/dbase/DTable.cxx index 5630800b47f2..0c3462eb1206 100644 --- a/connectivity/source/drivers/dbase/DTable.cxx +++ b/connectivity/source/drivers/dbase/DTable.cxx @@ -643,7 +643,7 @@ String ODbaseTable::getEntry(OConnection* _pConnection,const ::rtl::OUString& _s } xDir->beforeFirst(); // move back to before first record } - catch(Exception&) + catch(const Exception&) { OSL_ASSERT(0); } @@ -700,7 +700,7 @@ void ODbaseTable::refreshIndexes() aVector.push_back(aURL.getBase()); } } - catch(Exception&) // an exception is thrown when no file exists + catch(const Exception&) // an exception is thrown when no file exists { } } @@ -1064,7 +1064,7 @@ sal_Bool ODbaseTable::CreateImpl() delete pFileStream; } } - catch(Exception&) // an exception is thrown when no file exists + catch(const Exception&) // an exception is thrown when no file exists { } @@ -1081,7 +1081,7 @@ sal_Bool ODbaseTable::CreateImpl() Content aContent(aURL.GetMainURL(INetURLObject::NO_DECODE),Reference<XCommandEnvironment>()); aContent.executeCommand( rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("delete")),bool2any( sal_True ) ); } - catch(Exception&) // an exception is thrown when no file exists + catch(const Exception&) // an exception is thrown when no file exists { } return sal_False; @@ -1098,7 +1098,7 @@ sal_Bool ODbaseTable::CreateImpl() { bMemoAlreadyExists = aMemo1Content.isDocument(); } - catch(Exception&) // an exception is thrown when no file exists + catch(const Exception&) // an exception is thrown when no file exists { } if (bMemoAlreadyExists) @@ -1455,7 +1455,7 @@ sal_Bool ODbaseTable::Drop_Static(const ::rtl::OUString& _sUrl,sal_Bool _bHasMem _pIndexes->dropByIndex(--i); } } - catch(SQLException) + catch(const SQLException&) { } } @@ -1467,7 +1467,7 @@ sal_Bool ODbaseTable::Drop_Static(const ::rtl::OUString& _sUrl,sal_Bool _bHasMem ::ucbhelper::Content aDeleteContent( aURL.GetMainURL( INetURLObject::NO_DECODE ), Reference< XCommandEnvironment > () ); aDeleteContent.executeCommand( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("delete")), makeAny( sal_Bool( sal_True ) ) ); } - catch(Exception&) + catch(const Exception&) { // silently ignore this .... } @@ -1979,11 +1979,11 @@ sal_Bool ODbaseTable::UpdateBuffer(OValueRefVector& rRow, OValueRefRow pOrgRow,c break; } } - catch( SQLException& ) + catch( const SQLException& ) { throw; } - catch ( Exception& ) + catch ( const Exception& ) { m_pColumns->getByIndex(i) >>= xCol; OSL_ENSURE( xCol.is(), "ODbaseTable::UpdateBuffer column is null!" ); @@ -2333,7 +2333,7 @@ namespace if(aValues.getLength() && aValues[0].hasValue()) throw Exception(); } - catch(Exception&) + catch(const Exception&) { throw ElementExistException(newName,NULL); } |