summaryrefslogtreecommitdiff
path: root/sw/inc/unocrsr.hxx
diff options
context:
space:
mode:
authorStephan Bergmann <sbergman@redhat.com>2017-02-23 12:12:53 +0100
committerStephan Bergmann <sbergman@redhat.com>2017-02-23 12:12:53 +0100
commit73a9502ce8d06d729d8070721c4fc53c4e2b13dd (patch)
tree9779207bdea100b0dae5c2f65da74a7a90c1865c /sw/inc/unocrsr.hxx
parent280cd27dbdab438e63ecb2599ab5dd20e04d71d5 (diff)
Don't pass shared_ptr by value
...to avoid having to generate a temporary in e.g. SwXParagraphEnumeration::Create (sw/source/core/unocore/unoobj2.cxx), and thus to avoid <https://gcc.gnu.org/bugzilla/show_bug.cgi?id=79679> "[7 Regression] [C++17] Missing destruction of temporary within constructor's mem-initializer-list" Change-Id: Ifaa5a6d0e9baa77a19752f54e7765783139bea95
Diffstat (limited to 'sw/inc/unocrsr.hxx')
-rw-r--r--sw/inc/unocrsr.hxx2
1 files changed, 1 insertions, 1 deletions
diff --git a/sw/inc/unocrsr.hxx b/sw/inc/unocrsr.hxx
index 9ef520433dbf..d789bed5db39 100644
--- a/sw/inc/unocrsr.hxx
+++ b/sw/inc/unocrsr.hxx
@@ -111,7 +111,7 @@ namespace sw
UnoCursorPointer()
: m_pCursor(nullptr)
{}
- UnoCursorPointer(std::shared_ptr<SwUnoCursor> pCursor)
+ UnoCursorPointer(std::shared_ptr<SwUnoCursor> const & pCursor)
: m_pCursor(pCursor)
{
StartListening(m_pCursor->m_aNotifier);