From 7121e6a476101204978ce50828de2287948118a1 Mon Sep 17 00:00:00 2001 From: Jakub Bogusz Date: Wed, 18 Feb 2004 22:12:24 +0000 Subject: [PATCH] - fix for memory corruption when cross-linking PE DLL on 64-bit arch Changed files: binutils-pe-types.patch -> 1.1 --- binutils-pe-types.patch | 30 ++++++++++++++++++++++++++++++ 1 file changed, 30 insertions(+) create mode 100644 binutils-pe-types.patch diff --git a/binutils-pe-types.patch b/binutils-pe-types.patch new file mode 100644 index 0000000..706924e --- /dev/null +++ b/binutils-pe-types.patch @@ -0,0 +1,30 @@ +--- binutils-2.14.90.0.8/ld/pe-dll.c.orig 2004-01-14 21:07:52.000000000 +0000 ++++ binutils-2.14.90.0.8/ld/pe-dll.c 2004-02-18 21:56:38.000000000 +0000 +@@ -25,6 +25,7 @@ + #include "libiberty.h" + #include "safe-ctype.h" + ++#include + #include + + #include "ld.h" +@@ -916,8 +917,8 @@ + { + int s, hint; + unsigned char *edirectory; +- unsigned long *eaddresses; +- unsigned long *enameptrs; ++ uint32_t *eaddresses; ++ uint32_t *enameptrs; + unsigned short *eordinals; + unsigned char *enamestr; + time_t now; +@@ -928,7 +929,7 @@ + + /* Note use of array pointer math here. */ + edirectory = edata_d; +- eaddresses = (unsigned long *) (edata_d + 40); ++ eaddresses = (uint32_t *) (edata_d + 40); + enameptrs = eaddresses + export_table_size; + eordinals = (unsigned short *) (enameptrs + count_exported_byname); + enamestr = (char *) (eordinals + count_exported_byname); -- 2.44.0