It seems we over-optimised rtl_uString_alloc - which needs to always-alloc, and not return a ref-counted pointer to the const/static internal empty string (to avoid problems). People that alloc strings can usually cope with that. proximate problem: #0 com::sun::star::i18n::Transliteration_body::transliterate (this=0x9a6c250, inStr="", startPos=0, nCount=0, offset=empty uno::Sequence) at /ssd/opt/libreoffice/master/i18npool/source/transliteration/transliteration_body.cxx:144 #1 0xb1b59a55 in com::sun::star::i18n::TransliterationImpl::transliterate (this=0x9b67ff8, inStr="", startPos=0, nCount=0, offset=empty uno::Sequence) at /ssd/opt/libreoffice/master/i18npool/source/transliteration/transliterationImpl.cxx:315 #2 0xae1269f4 in TextSearch::searchForward (this=0x9b958c8, searchStr="", startPos=0, endPos=0) at /ssd/opt/libreoffice/master/i18npool/source/search/textsearch.cxx:200 #3 0xb6f9dfba in utl::TextSearch::SearchFrwrd (this=0x9c3a450, rStr="", pStart=0xbfffd4ce, pEnde=0xbfffd4d0, pRes=0xbfffd514) at /ssd/opt/libreoffice/master/unotools/source/i18n/textsearch.cxx:223 #4 0xb0bfff8f in ScTable::SearchCell (this=0x8a9e550, rSearchItem=..., nCol=0, nRow=1, rMark=..., rUndoStr="", pUndoDoc=0x0) at /ssd/opt/libreoffice/master/sc/source/core/data/table6.cxx:114 #5 0xb0c009ae in ScTable::Search (this=0x8a9e550, rSearchItem=..., rCol=@0xbfffd5da: 0, rRow=@0xbfffd5dc: 0, rMark=..., rUndoStr="", pUndoDoc= 0x0) at /ssd/opt/libreoffice/master/sc/source/core/data/table6.cxx:393 142 } 143 } 144 out[j] = 0; 145 146 return OUString( pStr, SAL_NO_ACQUIRE ); writing the terminating zero.
rtl_uString_alloc's docs also needed adjusting to match rtl_string_alloc's - normally the std::bad_alloc would be thrown in the C++ wrapper, potentially that might need adding ? about to commit a fix.
Michael Meeks committed a patch related to this issue. It has been pushed to "master": http://cgit.freedesktop.org/libreoffice/core/commit/?id=09123760860f99756d37b70557d83f707fda6b17 fdo#58473 - fix transliteration crasher caused by writing const string. The patch should be included in the daily builds available at http://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More information about daily builds can be found at: http://wiki.documentfoundation.org/Testing_Daily_Builds Affected users are encouraged to test the fix and report feedback.
fixed (I hope). Of course we could be more efficient in transliteration and not allocate empty strings we don't need but ... ;-)