diff options
author | Julien Nabet <serval2412@yahoo.fr> | 2021-06-03 07:06:53 +0200 |
---|---|---|
committer | Stephan Bergmann <sbergman@redhat.com> | 2021-06-03 09:38:58 +0200 |
commit | 23390e3096c2db2526cbc0867e3b2063e06f6150 (patch) | |
tree | 9d25edc73dbf23c54a65897fde5a7440f4984442 /dbaccess | |
parent | c6595e781cf20ab2825e9a2bd8592688f26448e3 (diff) |
Revert "Initialize vector directly with the already known count number"
This reverts commit da9fe0da11687bfc4c0eff2197286da67d6206c2.
Reason for revert: wrong result since there'll be first 4 by default initializations then an extra reserve allocation.
Change-Id: If480243e81db405d6a984b8450a219e486f1a1ff
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/116465
Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
Tested-by: Jenkins
Diffstat (limited to 'dbaccess')
-rw-r--r-- | dbaccess/source/core/api/HelperCollections.cxx | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/dbaccess/source/core/api/HelperCollections.cxx b/dbaccess/source/core/api/HelperCollections.cxx index 12ab6414dfed..dfc18badc688 100644 --- a/dbaccess/source/core/api/HelperCollections.cxx +++ b/dbaccess/source/core/api/HelperCollections.cxx @@ -53,7 +53,7 @@ namespace dbaccess std::unique_ptr<OPrivateColumns> OPrivateColumns::createWithIntrinsicNames( const ::rtl::Reference< ::connectivity::OSQLColumns >& _rColumns, bool _bCase, ::cppu::OWeakObject& _rParent, ::osl::Mutex& _rMutex ) { - std::vector< OUString > aNames(_rColumns->size()); + std::vector< OUString > aNames; aNames.reserve( _rColumns->size() ); OUString sColumName; for (auto const& column : *_rColumns) |