diff -r 8d55cb8b3831 -r 0a0e1eea6758 sw/source/filter/rtf/wrtrtf.cxx --- a/sw/source/filter/rtf/wrtrtf.cxx Thu Mar 18 14:24:20 2010 +0100 +++ b/sw/source/filter/rtf/wrtrtf.cxx Fri Mar 19 11:41:08 2010 +0100 @@ -85,6 +85,7 @@ const sal_Char __FAR_DATA SwRTFWriter::sNewLine[] = "\015\012"; #endif +static ::rtl::OUString aEmpty; SV_DECL_VARARR( RTFColorTbl, Color, 5, 8 ) @@ -1299,8 +1300,16 @@ Strm() << '}'; } OutComment( *this, OOO_STRING_SVTOOLS_RTF_BKMKEND ) << ' '; - RTFOutFuncs::Out_String( Strm(), pAsBookmark->GetName(), + + { + ::rtl::OUString & rBookmarkName = aEmpty; + + if (pAsBookmark) + rBookmarkName = pAsBookmark->GetName(); + + RTFOutFuncs::Out_String( Strm(), rBookmarkName, eDefaultEncoding, bWriteHelpFmt ) << '}'; + } if(++nBkmkTabPos >= pMarkAccess->getMarksCount()) nBkmkTabPos = -1;