diff options
author | Miklos Vajna <vmiklos@collabora.co.uk> | 2018-10-16 22:54:28 +0200 |
---|---|---|
committer | Miklos Vajna <vmiklos@collabora.co.uk> | 2018-10-17 10:51:04 +0200 |
commit | a463287a3bf12ee3f6f58311e2629da19e6d014b (patch) | |
tree | 1aca441d1bc121346ded8a8a487c46bd886f0947 /writerfilter | |
parent | bb480f77b8a65e7e52b53e601e536f55fa55f44b (diff) |
sw, writerfilter: avoid some unnecessary value parameters
Change-Id: I409eb644bdf519e097c87911b90f83c5ecd913ee
Reviewed-on: https://gerrit.libreoffice.org/61853
Tested-by: Jenkins
Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk>
Diffstat (limited to 'writerfilter')
-rw-r--r-- | writerfilter/source/rtftok/rtfsprm.cxx | 2 | ||||
-rw-r--r-- | writerfilter/source/rtftok/rtfsprm.hxx | 3 |
2 files changed, 3 insertions, 2 deletions
diff --git a/writerfilter/source/rtftok/rtfsprm.cxx b/writerfilter/source/rtftok/rtfsprm.cxx index f5f32f186d42..a4f3b81be211 100644 --- a/writerfilter/source/rtftok/rtfsprm.cxx +++ b/writerfilter/source/rtftok/rtfsprm.cxx @@ -76,7 +76,7 @@ RTFValue::Pointer_t RTFSprms::find(Id nKeyword, bool bFirst, bool bForWrite) return pValue; } -void RTFSprms::set(Id nKeyword, RTFValue::Pointer_t pValue, RTFOverwrite eOverwrite) +void RTFSprms::set(Id nKeyword, const RTFValue::Pointer_t& pValue, RTFOverwrite eOverwrite) { ensureCopyBeforeWrite(); diff --git a/writerfilter/source/rtftok/rtfsprm.hxx b/writerfilter/source/rtftok/rtfsprm.hxx index e46a7b68881f..cc5fb73ff13f 100644 --- a/writerfilter/source/rtftok/rtfsprm.hxx +++ b/writerfilter/source/rtftok/rtfsprm.hxx @@ -55,7 +55,8 @@ public: RTFValue::Pointer_t find(Id nKeyword, bool bFirst = true, bool bForWrite = false); /// Does the same as ->push_back(), except that it can overwrite or ignore existing entries. - void set(Id nKeyword, RTFValue::Pointer_t pValue, RTFOverwrite eOverwrite = RTFOverwrite::YES); + void set(Id nKeyword, const RTFValue::Pointer_t& pValue, + RTFOverwrite eOverwrite = RTFOverwrite::YES); bool erase(Id nKeyword); void eraseLast(Id nKeyword); /// Removes elements which are already in the reference set. |