sw/source/core/doc/doc.cxx | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)
New commits: commit 02172de1a9c1f4442514cc79583ecd0a46331f45 Author: Michael Stahl <mst...@redhat.com> Date: Thu Feb 6 13:02:19 2014 +0100 SwDoc::ConvertFieldsToText(): don't insert empty strings Prevents an assert on accessing sText[0] in InsertString(). Manually cherry-picked from 85a8c1361dccb2c3b98458c2c1c377d5de275d0e to resolve fdo#77720, see bt here https://bugs.freedesktop.org/attachment.cgi?id=97684 Change-Id: I1828694a4c1e46f8b48cf3571ec2bf4dd615bf2c Reviewed-on: https://gerrit.libreoffice.org/9113 Reviewed-by: Miklos Vajna <vmik...@collabora.co.uk> Tested-by: Miklos Vajna <vmik...@collabora.co.uk> diff --git a/sw/source/core/doc/doc.cxx b/sw/source/core/doc/doc.cxx index 6382d74..e1d84f3 100644 --- a/sw/source/core/doc/doc.cxx +++ b/sw/source/core/doc/doc.cxx @@ -2427,7 +2427,8 @@ bool SwDoc::ConvertFieldsToText() SwPaM aPam1(*pTxtFld->GetpTxtNode(), *pTxtFld->GetStart()); aPam1.Move(); //insert first to keep the field's attributes - InsertString( aPam1, sText ); + if (!sText.isEmpty()) + InsertString( aPam1, sText ); SwPaM aPam2(*pTxtFld->GetpTxtNode(), *pTxtFld->GetStart()); aPam2.SetMark(); aPam2.Move(); _______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits