diff options
author | Noel Grandin <noel.grandin@collabora.co.uk> | 2023-06-02 20:51:53 +0200 |
---|---|---|
committer | Noel Grandin <noel.grandin@collabora.co.uk> | 2023-06-03 10:43:14 +0200 |
commit | 7a5847b3716ac64ad422f24164c0b765610ffbd7 (patch) | |
tree | 1c7757c4ae7eec92baccaade079fdee316666695 /sc | |
parent | 7daf830830609cbb13a01ae55634187718c84d8a (diff) |
remove unnecessary ScPatternAttr copy
slightly speeds up loading document with large number of patterns
Change-Id: I1b82145fb0f8a62da0d5a46a43594f7085ce2c22
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/152564
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'sc')
-rw-r--r-- | sc/source/core/data/table2.cxx | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/sc/source/core/data/table2.cxx b/sc/source/core/data/table2.cxx index 1bceab692e54..b3a5b9aee9b9 100644 --- a/sc/source/core/data/table2.cxx +++ b/sc/source/core/data/table2.cxx @@ -2902,8 +2902,7 @@ namespace std::vector<ScAttrEntry> aData(rOrigData); for (size_t nIdx = 0; nIdx < aData.size(); ++nIdx) { - ScPatternAttr aNewPattern(*aData[nIdx].pPattern); - aData[nIdx].pPattern = &rDocument.GetPool()->Put(aNewPattern); + aData[nIdx].pPattern = &rDocument.GetPool()->Put(*aData[nIdx].pPattern); } return aData; } |