Including a patch from AOO...

Norbert Thiebaud nthiebaud at gmail.com
Wed Jun 27 09:53:45 PDT 2012


On Wed, Jun 27, 2012 at 8:41 AM, Ivan Timofeev <timofeev.i.s at gmail.com> wrote:
> Hi there,
>
> a nice patch from AOO:
>
>  http://svn.apache.org/viewvc?view=revision&revision=1350585

given that the entirety of the patch is:
--- incubator/ooo/trunk/main/svl/source/undo/undo.cxx	2012/06/15
11:40:33	1350584
+++ incubator/ooo/trunk/main/svl/source/undo/undo.cxx	2012/06/15
11:42:45	1350585
@@ -627,7 +627,7 @@
     // merge, if required
 	SfxUndoAction* pMergeWithAction = m_pData->pActUndoArray->nCurUndoAction ?
 		m_pData->pActUndoArray->aUndoActions[m_pData->pActUndoArray->nCurUndoAction-1].pAction
: NULL;
-	if ( bTryMerge && ( !pMergeWithAction || !pMergeWithAction->Merge(
pAction ) ) )
+	if ( bTryMerge && ( pMergeWithAction && pMergeWithAction->Merge( pAction ) ) )
     {
         i_guard.markForDeletion( pAction );
         return false;

Just reproduce it and mention i119400 in the commit message.

Note: in this specific case removing the unnecessary '()' [ indeed A
&& (B && C) <=> A && B && C ]
would be enough to make a distinct enough implementation, should
someone insist on the un-realistic concept that such patch rise to the
creativity threshold.

Norbert


More information about the LibreOffice mailing list