summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--sw/source/core/txtnode/ndtxt.cxx4
1 files changed, 2 insertions, 2 deletions
diff --git a/sw/source/core/txtnode/ndtxt.cxx b/sw/source/core/txtnode/ndtxt.cxx
index ee1dd0185295..2cc28ae00390 100644
--- a/sw/source/core/txtnode/ndtxt.cxx
+++ b/sw/source/core/txtnode/ndtxt.cxx
@@ -3337,9 +3337,9 @@ void SwTxtNode::ReplaceText( const SwIndex& rStart, const xub_StrLen nDelLen,
"SwTxtNode::ReplaceText: node text with insertion > TXTNODE_MAX.");
OUString const sInserted(
(nOverflow > 0) ? rStr.Copy(0, rStr.Len() - nOverflow) : rStr);
- if (sInserted.isEmpty())
+ if (sInserted.isEmpty() && 0 == nDelLen)
{
- return;
+ return; // nothing to do
}
const xub_StrLen nStartPos = rStart.GetIndex();