[Libreoffice-commits] core.git: sw/source
Michael Stahl (via logerrit)
logerrit at kemper.freedesktop.org
Thu Nov 19 08:29:56 UTC 2020
sw/source/core/txtnode/ndtxt.cxx | 7 +++++--
1 file changed, 5 insertions(+), 2 deletions(-)
New commits:
commit 53f17e2a0f2a113a8b677940a314b5934c49acc3
Author: Michael Stahl <Michael.Stahl at cib.de>
AuthorDate: Wed Nov 18 15:48:28 2020 +0100
Commit: Michael Stahl <michael.stahl at cib.de>
CommitDate: Thu Nov 19 09:29:17 2020 +0100
sw_redlinehide: fix assert on Replace with nothing
SwTextNode::ReplaceText() doesn't need to notify in that case, avoids
assert in UpdateMergedParaForInsert(), seen in
testDateFormFieldContentOperations.
Change-Id: Ie80c14bc903d91a289f470f8a732932342a283be
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/106062
Tested-by: Jenkins
Reviewed-by: Michael Stahl <michael.stahl at cib.de>
diff --git a/sw/source/core/txtnode/ndtxt.cxx b/sw/source/core/txtnode/ndtxt.cxx
index fdac201aa618..e4cd823d74e0 100644
--- a/sw/source/core/txtnode/ndtxt.cxx
+++ b/sw/source/core/txtnode/ndtxt.cxx
@@ -3712,8 +3712,11 @@ void SwTextNode::ReplaceText( const SwIndex& rStart, const sal_Int32 nDelLen,
SwDelText aDelHint( nStartPos, nDelLen );
NotifyClients( nullptr, &aDelHint );
- SwInsText aHint( nStartPos, sInserted.getLength() );
- NotifyClients( nullptr, &aHint );
+ if (sInserted.getLength())
+ {
+ SwInsText aHint( nStartPos, sInserted.getLength() );
+ NotifyClients( nullptr, &aHint );
+ }
}
namespace {
More information about the Libreoffice-commits
mailing list