]> git.pld-linux.org Git - packages/crossmingw32-binutils.git/blob - binutils-pe-types.patch
- fix for memory corruption when cross-linking PE DLL on 64-bit arch
[packages/crossmingw32-binutils.git] / binutils-pe-types.patch
1 --- binutils-2.14.90.0.8/ld/pe-dll.c.orig       2004-01-14 21:07:52.000000000 +0000
2 +++ binutils-2.14.90.0.8/ld/pe-dll.c    2004-02-18 21:56:38.000000000 +0000
3 @@ -25,6 +25,7 @@
4  #include "libiberty.h"
5  #include "safe-ctype.h"
6  
7 +#include <stdint.h>
8  #include <time.h>
9  
10  #include "ld.h"
11 @@ -916,8 +917,8 @@
12  {
13    int s, hint;
14    unsigned char *edirectory;
15 -  unsigned long *eaddresses;
16 -  unsigned long *enameptrs;
17 +  uint32_t *eaddresses;
18 +  uint32_t *enameptrs;
19    unsigned short *eordinals;
20    unsigned char *enamestr;
21    time_t now;
22 @@ -928,7 +929,7 @@
23  
24    /* Note use of array pointer math here.  */
25    edirectory = edata_d;
26 -  eaddresses = (unsigned long *) (edata_d + 40);
27 +  eaddresses = (uint32_t *) (edata_d + 40);
28    enameptrs = eaddresses + export_table_size;
29    eordinals = (unsigned short *) (enameptrs + count_exported_byname);
30    enamestr = (char *) (eordinals + count_exported_byname);
This page took 0.040512 seconds and 3 git commands to generate.