diff options
author | Noel Grandin <noel.grandin@collabora.co.uk> | 2020-04-17 11:24:14 +0200 |
---|---|---|
committer | Noel Grandin <noel.grandin@collabora.co.uk> | 2020-04-17 12:09:30 +0200 |
commit | 034e9eee277d5123258fedc1861edf49c99159ef (patch) | |
tree | 695219b776c3fcd61fa614800d2789866e8865d2 /dbaccess/source/core/api/RowSet.cxx | |
parent | 8e5a43223ce421643213e6542c6a971b6164f6aa (diff) |
loplugin:buriedassign in dbaccess
Change-Id: Ia97da8d228a8c4e3ced31718a756fb13757beb8f
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/92407
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'dbaccess/source/core/api/RowSet.cxx')
-rw-r--r-- | dbaccess/source/core/api/RowSet.cxx | 15 |
1 files changed, 10 insertions, 5 deletions
diff --git a/dbaccess/source/core/api/RowSet.cxx b/dbaccess/source/core/api/RowSet.cxx index f652dc0e60cd..b197d28787a1 100644 --- a/dbaccess/source/core/api/RowSet.cxx +++ b/dbaccess/source/core/api/RowSet.cxx @@ -1284,8 +1284,10 @@ const ORowSetValue& ORowSet::getInsertValue(sal_Int32 columnIndex) checkCache(); if ( m_pCache && isInsertRow() ) - return (**m_pCache->m_aInsertRow)[m_nLastColumnIndex = columnIndex]; - + { + m_nLastColumnIndex = columnIndex; + return (**m_pCache->m_aInsertRow)[m_nLastColumnIndex]; + } return getValue(columnIndex); } @@ -1368,7 +1370,8 @@ Reference< css::io::XInputStream > SAL_CALL ORowSet::getBinaryStream( sal_Int32 if ( m_pCache && isInsertRow() ) { checkCache(); - return new ::comphelper::SequenceInputStream((**m_pCache->m_aInsertRow)[m_nLastColumnIndex = columnIndex].getSequence()); + m_nLastColumnIndex = columnIndex; + return new ::comphelper::SequenceInputStream((**m_pCache->m_aInsertRow)[m_nLastColumnIndex].getSequence()); } return ORowSetBase::getBinaryStream(columnIndex); @@ -1380,7 +1383,8 @@ Reference< css::io::XInputStream > SAL_CALL ORowSet::getCharacterStream( sal_Int if(m_pCache && isInsertRow() ) { checkCache(); - return new ::comphelper::SequenceInputStream((**m_pCache->m_aInsertRow)[m_nLastColumnIndex = columnIndex].getSequence()); + m_nLastColumnIndex = columnIndex; + return new ::comphelper::SequenceInputStream((**m_pCache->m_aInsertRow)[m_nLastColumnIndex].getSequence()); } return ORowSetBase::getCharacterStream(columnIndex); @@ -1402,7 +1406,8 @@ Reference< XBlob > SAL_CALL ORowSet::getBlob( sal_Int32 columnIndex ) if ( m_pCache && isInsertRow() ) { checkCache(); - return new ::connectivity::BlobHelper((**m_pCache->m_aInsertRow)[m_nLastColumnIndex = columnIndex].getSequence()); + m_nLastColumnIndex = columnIndex; + return new ::connectivity::BlobHelper((**m_pCache->m_aInsertRow)[m_nLastColumnIndex].getSequence()); } return ORowSetBase::getBlob(columnIndex); } |