From: Abdelrazak Younes Date: Tue, 28 Oct 2008 17:41:56 +0000 (+0000) Subject: Fix bug http://bugzilla.lyx.org/show_bug.cgi?id=5423 X-Git-Tag: 1.6.10~2800 X-Git-Url: https://git.lyx.org/gitweb/?a=commitdiff_plain;h=bc79c203a9da0a3ed8a4469374c10b34e427e8b9;p=features.git Fix bug http://bugzilla.lyx.org/show_bug.cgi?id=5423 This regression was introduced by at r26957, sorry about that. git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@27168 a592a061-630c-0410-9148-cb99ea01b6c8 --- diff --git a/src/paragraph_funcs.cpp b/src/paragraph_funcs.cpp index e59e4a5909..a11d72550e 100644 --- a/src/paragraph_funcs.cpp +++ b/src/paragraph_funcs.cpp @@ -36,8 +36,9 @@ static bool moveItem(Paragraph & fromPar, pos_type fromPos, // Note: moveItem() does not honour change tracking! // Therefore, it should only be used for breaking and merging paragraphs - Font const & tmpFont = fromPar.getFontSettings(params, fromPos); - Change const & tmpChange = fromPar.lookupChange(fromPos); + // We need a copy here because the character at fromPos is going to be erased. + Font const tmpFont = fromPar.getFontSettings(params, fromPos); + Change const tmpChange = fromPar.lookupChange(fromPos); if (Inset * tmpInset = fromPar.getInset(fromPos)) { fromPar.releaseInset(fromPos);