diff options
Diffstat (limited to 'connectivity/source/drivers/postgresql/pq_xviews.cxx')
-rw-r--r-- | connectivity/source/drivers/postgresql/pq_xviews.cxx | 11 |
1 files changed, 4 insertions, 7 deletions
diff --git a/connectivity/source/drivers/postgresql/pq_xviews.cxx b/connectivity/source/drivers/postgresql/pq_xviews.cxx index 311fb888494a..31b4c355bdbd 100644 --- a/connectivity/source/drivers/postgresql/pq_xviews.cxx +++ b/connectivity/source/drivers/postgresql/pq_xviews.cxx @@ -163,10 +163,8 @@ void Views::dropByName( const OUString& elementName ) String2IntMap::const_iterator ii = m_name2index.find( elementName ); if( ii == m_name2index.end() ) { - OUStringBuffer buf( 128 ); - buf.append( "View " + elementName + " is unknown, so it can't be dropped" ); throw css::container::NoSuchElementException( - buf.makeStringAndClear(), *this ); + "View " + elementName + " is unknown, so it can't be dropped", *this ); } dropByIndex( ii->second ); } @@ -176,11 +174,10 @@ void Views::dropByIndex( sal_Int32 index ) osl::MutexGuard guard( m_refMutex->mutex ); if( index < 0 || index >= (sal_Int32)m_values.size() ) { - OUStringBuffer buf( 128 ); - buf.append( "VIEWS: Index out of range (allowed 0 to " + OUString::number(m_values.size() -1) + - ", got " + OUString::number( index ) + ")"); throw css::lang::IndexOutOfBoundsException( - buf.makeStringAndClear(), *this ); + "VIEWS: Index out of range (allowed 0 to " + OUString::number(m_values.size() -1) + + ", got " + OUString::number( index ) + ")", + *this ); } Reference< XPropertySet > set; |