https://bugs.documentfoundation.org/show_bug.cgi?id=83306

--- Comment #12 from Michael Stahl <mst...@redhat.com> ---
the bug is triggered in compare_WithLength, in

+    if (sizeof(IMPL_RTL_STRCODE) == sizeof(wchar_t))
+    {
+        // take advantage of builtin optimisations
+        sal_Int32 nMin = std::min(nStr1Len, nStr2Len);
+        sal_Int32 nRet = wcsncmp((wchar_t*)pStr1, (wchar_t*)pStr2, nMin);
+        return nRet == 0 ? nStr1Len - nStr2Len : nRet;
+    }


the problem is that the oox code uses strings with embedded null bytes
to identify shapes (why?), and wcsncmp stops at the first null byte
but the old code would compare them too.  this causes different results.

-- 
You are receiving this mail because:
You are the assignee for the bug.
_______________________________________________
Libreoffice-bugs mailing list
Libreoffice-bugs@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-bugs

Reply via email to