diff options
author | liqingqing <liqingqing3@huawei.com> | 2020-10-22 17:11:44 +0800 |
---|---|---|
committer | DJ Delorie <dj@redhat.com> | 2020-10-30 14:49:08 -0400 |
commit | 961d12d9471f0178441e67e073ba2f3085cf20f1 (patch) | |
tree | 2d8a9e44cea0e5eb1e0f95b3c642e094260e1dd6 /malloc/hooks.c | |
parent | 024f873209f531322661578d3468b1f0a132640c (diff) | |
download | glibc-961d12d9471f0178441e67e073ba2f3085cf20f1.tar glibc-961d12d9471f0178441e67e073ba2f3085cf20f1.tar.gz glibc-961d12d9471f0178441e67e073ba2f3085cf20f1.tar.bz2 glibc-961d12d9471f0178441e67e073ba2f3085cf20f1.zip |
malloc debug: fix compile error when enable macro MALLOC_DEBUG > 1
malloc debug: fix compile error when enable macro MALLOC_DEBUG > 1.
this is because commit e9c4fe93b3855239752819303ca377dff0ed0553 has change the struct malloc_chunk's member "size" to "mchunk_size".
the reproduction is like that:
setp1: modify related Makefile.
vim ../glibc/malloc/Makefile
CPPFLAGS-malloc.o += -DMALLOC_DEBUG=2
step2: ../configure --prefix=/usr
make -j32
this will cause the compile error:
/home/liqingqing/glibc_upstream/buildglibc/malloc/malloc.o
In file included from malloc.c:1899:0:
arena.c: In function 'dump_heap':
arena.c:422:58: error: 'struct malloc_chunk' has no member named 'size'
fprintf (stderr, "chunk %p size %10lx", p, (long) p->size);
^~
arena.c:428:17: error: 'struct malloc_chunk' has no member named 'size'
else if (p->size == (0 | PREV_INUSE))
Reviewed-by: DJ Delorie <dj@redhat.com>
Diffstat (limited to 'malloc/hooks.c')
0 files changed, 0 insertions, 0 deletions