sw/source/core/undo/rolbck.cxx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
New commits: commit ec580f5ee7b40b9d778cce41fdff08276fecfe54 Author: Mike Kaganski <[email protected]> AuthorDate: Mon Sep 30 11:57:40 2019 +0200 Commit: Mike Kaganski <[email protected]> CommitDate: Mon Sep 30 14:47:41 2019 +0200 pNew could be nullptr Both if branches dereference pNew, so just check for that instead of useless check for ( pOld || pNew ) which is granted if pOld != pNew Change-Id: I5654c0a4e12e614d4d2068ddae582c1b86f2d61f Reviewed-on: https://gerrit.libreoffice.org/79837 Reviewed-by: Michael Stahl <[email protected]> Tested-by: Jenkins Reviewed-by: Mike Kaganski <[email protected]> diff --git a/sw/source/core/undo/rolbck.cxx b/sw/source/core/undo/rolbck.cxx index 2fbc1356f4cf..a80d270cb81f 100644 --- a/sw/source/core/undo/rolbck.cxx +++ b/sw/source/core/undo/rolbck.cxx @@ -1298,7 +1298,7 @@ SwRegHistory::SwRegHistory( const SwNode& rNd, SwHistory* pHst ) void SwRegHistory::Modify( const SfxPoolItem* pOld, const SfxPoolItem* pNew ) { - if ( m_pHistory && ( pOld || pNew ) && pOld != pNew ) + if ( m_pHistory && pNew && pOld != pNew ) { if ( pNew->Which() < POOLATTR_END ) { _______________________________________________ Libreoffice-commits mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits
