libexttextcat/UnpackedTarball_exttextcat.mk | 1 + libexttextcat/exttextcat-memcpy.patch.1 | 16 ++++++++++++++++ 2 files changed, 17 insertions(+)
New commits: commit b82577140f0bbb63e127caae7779adb04bd9c099 Author: Michael Stahl <mst...@redhat.com> Date: Thu Jul 4 23:12:53 2013 +0200 libexttextcat: fix overlapping memcpy (cherry picked from commit 3bde0af3a8fd09defd47465d4b62541350cecc1c) Conflicts: libexttextcat/UnpackedTarball_exttextcat.mk Change-Id: I3225043560a3c0e02345bc4e8a8d0f9cca2e3cd0 Reviewed-on: https://gerrit.libreoffice.org/4730 Reviewed-by: Fridrich Strba <fridr...@documentfoundation.org> Tested-by: Fridrich Strba <fridr...@documentfoundation.org> diff --git a/libexttextcat/UnpackedTarball_exttextcat.mk b/libexttextcat/UnpackedTarball_exttextcat.mk index c6fa03c..a96b02b 100644 --- a/libexttextcat/UnpackedTarball_exttextcat.mk +++ b/libexttextcat/UnpackedTarball_exttextcat.mk @@ -14,6 +14,7 @@ $(eval $(call gb_UnpackedTarball_set_tarball,exttextcat,$(LIBEXTTEXTCAT_TARBALL) $(eval $(call gb_UnpackedTarball_add_patches,exttextcat,\ libexttextcat/android.patch \ libexttextcat/unkown.patch.1 \ + libexttextcat/exttextcat-memcpy.patch.1 \ )) # vim: set noet sw=4 ts=4: diff --git a/libexttextcat/exttextcat-memcpy.patch.1 b/libexttextcat/exttextcat-memcpy.patch.1 new file mode 100644 index 0000000..b3e399a --- /dev/null +++ b/libexttextcat/exttextcat-memcpy.patch.1 @@ -0,0 +1,16 @@ +fix overlapped memcpy in heapextract + +--- a/src/fingerprint.c 2013-07-04 22:53:25.674741538 +0200 ++++ b/src/fingerprint.c 2013-07-04 22:54:09.009741166 +0200 +@@ -254,7 +254,10 @@ + p = &(t->heap[0]); + + memcpy(item, p, sizeof(entry_t)); +- memcpy(&(t->heap[0]), &(t->heap[t->size - 1]), sizeof(entry_t)); ++ if (t->size > 1) ++ { ++ memcpy(&(t->heap[0]), &(t->heap[t->size - 1]), sizeof(entry_t)); ++ } + + siftdown(t, t->size, 0); + t->size--; _______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits