From 3669bb966f709089f43111b5ca1057bfe4a22697 Mon Sep 17 00:00:00 2001 From: Caolán McNamara Date: Sun, 15 Jul 2012 20:46:27 +0100 Subject: Resolves: fdo#52013 use vector::insert instead Change-Id: Ie12e5b11196b1b0f919bd18f28a0b86f60cc6513 Signed-off-by: Takeshi Abe --- sw/source/core/inc/rolbck.hxx | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'sw/source/core') diff --git a/sw/source/core/inc/rolbck.hxx b/sw/source/core/inc/rolbck.hxx index efb6f41cf331..cd5a9473e0ef 100644 --- a/sw/source/core/inc/rolbck.hxx +++ b/sw/source/core/inc/rolbck.hxx @@ -402,7 +402,8 @@ public: { SwpHstry::iterator itSourceBegin = pIns->m_SwpHstry.begin() + nStart; SwpHstry::iterator itSourceEnd = pIns->m_SwpHstry.end(); - std::copy( itSourceBegin, itSourceEnd, m_SwpHstry.begin() + nPos ); + if (itSourceBegin == itSourceEnd) return; + m_SwpHstry.insert(m_SwpHstry.begin() + nPos, itSourceBegin, itSourceEnd); pIns->m_SwpHstry.erase( itSourceBegin, itSourceEnd ); } -- cgit v1.2.3