Kaydet (Commit) b51d9c63 authored tarafından Michael Stahl's avatar Michael Stahl

sw: avoid calling convertToString() with unsupported encodings

Change-Id: If0b589c884cd306ca7c94d3366af66276a120176
üst c00d8161
...@@ -728,7 +728,8 @@ namespace sw ...@@ -728,7 +728,8 @@ namespace sw
sal_uInt8 nRet = sal_uInt8 nRet =
rtl_getBestWindowsCharsetFromTextEncoding(eTextEncoding); rtl_getBestWindowsCharsetFromTextEncoding(eTextEncoding);
rtl_TextEncoding enc2 = rtl_getTextEncodingFromWindowsCharset(nRet); rtl_TextEncoding enc2 = rtl_getTextEncodingFromWindowsCharset(nRet);
if (!(CanEncode(rFontName, enc2) && CanEncode(rAltName, enc2))) if (!rtl_isOctetTextEncoding(enc2) /* check to avoid asserts */ ||
!(CanEncode(rFontName, enc2) && CanEncode(rAltName, enc2)))
{ {
static struct { rtl_TextEncoding enc; sal_uInt8 charset; } static struct { rtl_TextEncoding enc; sal_uInt8 charset; }
const s_fallbacks [] = { const s_fallbacks [] = {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment