sal/textenc/handleundefinedunicodetotextchar.cxx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
New commits: commit 51bfb3a5af91dcd17ebc4c52845e77f530f05c6d Author: Markus Mohrhard <[email protected]> Date: Mon May 5 02:29:55 2014 +0200 Asan: fix invalid memory access Change-Id: I7a2acd99f3a8cb143c2ad1c978dfa4b02bf54464 Signed-off-by: Stephan Bergmann <[email protected]> diff --git a/sal/textenc/handleundefinedunicodetotextchar.cxx b/sal/textenc/handleundefinedunicodetotextchar.cxx index 6ea1dad..7ff7bd0 100644 --- a/sal/textenc/handleundefinedunicodetotextchar.cxx +++ b/sal/textenc/handleundefinedunicodetotextchar.cxx @@ -108,7 +108,7 @@ bool sal::detail::textenc::handleUndefinedUnicodeToTextChar( /* one replacement character */ if (ImplIsHighSurrogate(c)) { - if ( *ppSrcBuf == pEndSrcBuf ) + if ( ((*ppSrcBuf) + 1) == pEndSrcBuf ) { *pInfo |= RTL_UNICODETOTEXT_INFO_ERROR | RTL_UNICODETOTEXT_INFO_SRCBUFFERTOSMALL; return false; _______________________________________________ Libreoffice-commits mailing list [email protected] http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits
