diff options
author | Michael Stahl <mstahl@redhat.com> | 2014-06-26 17:09:07 +0200 |
---|---|---|
committer | Michael Stahl <mstahl@redhat.com> | 2014-06-27 16:15:18 +0200 |
commit | b51d9c633c2b5d03478be7b175fdbea367376c72 (patch) | |
tree | 6d01ffb9b846ebdd0c6d15e958f3adff1db947df /sw | |
parent | c00d81612e128b74c23c95e011b482dc3918fca4 (diff) |
sw: avoid calling convertToString() with unsupported encodings
Change-Id: If0b589c884cd306ca7c94d3366af66276a120176
Diffstat (limited to 'sw')
-rw-r--r-- | sw/source/filter/ww8/writerwordglue.cxx | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/sw/source/filter/ww8/writerwordglue.cxx b/sw/source/filter/ww8/writerwordglue.cxx index 56f92840376e..ddc83138ed0e 100644 --- a/sw/source/filter/ww8/writerwordglue.cxx +++ b/sw/source/filter/ww8/writerwordglue.cxx @@ -728,7 +728,8 @@ namespace sw sal_uInt8 nRet = rtl_getBestWindowsCharsetFromTextEncoding(eTextEncoding); 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; } const s_fallbacks [] = { |