diff options
author | Julien Nabet <serval2412@yahoo.fr> | 2021-10-22 16:33:48 +0200 |
---|---|---|
committer | Julien Nabet <serval2412@yahoo.fr> | 2021-10-22 18:05:12 +0200 |
commit | 11dfb73eec6ae94ebb52cbbbb6bdf9267fbb717b (patch) | |
tree | 0a8b3242edae2f8a4f265241793f07f8c226703c /dbaccess | |
parent | c4b934128965cbd461f1c61255fe0c5d25cc29d6 (diff) |
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 <serval2412@yahoo.fr>
Diffstat (limited to 'dbaccess')
-rw-r--r-- | dbaccess/source/ui/uno/copytablewizard.cxx | 6 |
1 files changed, 4 insertions, 2 deletions
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 ) { |