dbaccess/source/ui/uno/copytablewizard.cxx | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-)
New commits: commit 11dfb73eec6ae94ebb52cbbbb6bdf9267fbb717b Author: Julien Nabet <serval2...@yahoo.fr> AuthorDate: Fri Oct 22 16:33:48 2021 +0200 Commit: Julien Nabet <serval2...@yahoo.fr> CommitDate: Fri Oct 22 18:05:12 2021 +0200 Revert "Simplify vector initialization in dbaccess" This reverts commit dfa8dbf98ee872d22bb9e2c63ab07ed76fb81579. since it needs 2 allocations instead of one Change-Id: I64d449ca885880f3e6e795168978ffa99a005c37 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/124067 Tested-by: Jenkins Reviewed-by: Julien Nabet <serval2...@yahoo.fr> diff --git a/dbaccess/source/ui/uno/copytablewizard.cxx b/dbaccess/source/ui/uno/copytablewizard.cxx index d343dc4149f1..9ebd7d6df288 100644 --- a/dbaccess/source/ui/uno/copytablewizard.cxx +++ b/dbaccess/source/ui/uno/copytablewizard.cxx @@ -1077,11 +1077,13 @@ void CopyTableWizard::impl_copyRows_throw( const Reference< XResultSet >& _rxSou // we need a vector which all types sal_Int32 nCount = xMeta->getColumnCount(); - std::vector< sal_Int32 > aSourceColTypes { -1 };// just to avoid an every time i-1 call + std::vector< sal_Int32 > aSourceColTypes; aSourceColTypes.reserve( nCount + 1 ); + aSourceColTypes.push_back( -1 ); // just to avoid an every time i-1 call - std::vector< sal_Int32 > aSourcePrec { -1 }; // just to avoid an every time i-1 call + std::vector< sal_Int32 > aSourcePrec; aSourcePrec.reserve( nCount + 1 ); + aSourcePrec.push_back( -1 ); // just to avoid an every time i-1 call for ( sal_Int32 k=1; k <= nCount; ++k ) {