From e582c5eda2fea3cdb336f35a070997588b8ccf96 Mon Sep 17 00:00:00 2001 From: Ulrich Drepper Date: Mon, 4 Oct 2004 23:22:47 +0000 Subject: Update. 2004-10-04 Ulrich Drepper * malloc/mtrace.pl: Avoid calling location unless it is needed for output. Patch by Edward Bishop . * nscd/Makefile (CFLAGS-gai.c): Add -fpie. --- ChangeLog | 7 +++++++ malloc/mtrace.pl | 15 ++++++++------- nscd/Makefile | 1 + 3 files changed, 16 insertions(+), 7 deletions(-) diff --git a/ChangeLog b/ChangeLog index d360290..f45ef42 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,10 @@ +2004-10-04 Ulrich Drepper + + * malloc/mtrace.pl: Avoid calling location unless it is needed for + output. Patch by Edward Bishop . + + * nscd/Makefile (CFLAGS-gai.c): Add -fpie. + 2004-10-04 H.J. Lu * sysdeps/unix/sysv/linux/ia64/clock_getcpuclockid.c diff --git a/malloc/mtrace.pl b/malloc/mtrace.pl index 2d12929..1640fa6 100644 --- a/malloc/mtrace.pl +++ b/malloc/mtrace.pl @@ -165,17 +165,18 @@ while () { if ($cols[$n] eq "+") { if (defined $allocated{$allocaddr}) { printf ("+ %#0@XXX@x Alloc %d duplicate: %s %s\n", - hex($allocaddr), $nr, $wherewas{$allocaddr}, $where); + hex($allocaddr), $nr, &location($addrwas{$allocaddr}), + $where); } else { $allocated{$allocaddr}=$howmuch; - $wherewas{$allocaddr}=&location($where); + $addrwas{$allocaddr}=$where; } last SWITCH; } if ($cols[$n] eq "-") { if (defined $allocated{$allocaddr}) { undef $allocated{$allocaddr}; - undef $wherewas{$allocaddr}; + undef $addrwas{$allocaddr}; } else { printf ("- %#0@XXX@x Free %d was never alloc'd %s\n", hex($allocaddr), $nr, &location($where)); @@ -185,7 +186,7 @@ while () { if ($cols[$n] eq "<") { if (defined $allocated{$allocaddr}) { undef $allocated{$allocaddr}; - undef $wherewas{$allocaddr}; + undef $addrwas{$allocaddr}; } else { printf ("- %#0@XXX@x Realloc %d was never alloc'd %s\n", hex($allocaddr), $nr, &location($where)); @@ -196,10 +197,10 @@ while () { if (defined $allocated{$allocaddr}) { printf ("+ %#0@XXX@x Realloc %d duplicate: %#010x %s %s\n", hex($allocaddr), $nr, $allocated{$allocaddr}, - $wherewas{$allocaddr}, &location($where)); + &location($addrwas{$allocaddr}), &location($where)); } else { $allocated{$allocaddr}=$howmuch; - $wherewas{$allocaddr}=&location($where); + $addrwas{$allocaddr}=$where; } last SWITCH; } @@ -227,7 +228,7 @@ if ($#addrs >= 0) { $anything=1; } printf ("%#0@XXX@x %#8x at %s\n", hex($addr), $allocated{$addr}, - $wherewas{$addr}); + &location($addrwas{$addr})); } } } diff --git a/nscd/Makefile b/nscd/Makefile index 3418624..16d67bd 100644 --- a/nscd/Makefile +++ b/nscd/Makefile @@ -92,6 +92,7 @@ CFLAGS-nscd_setup_thread.c += -fpie CFLAGS-aicache.c += -fpie CFLAGS-selinux.c += -fpie CFLAGS-initgrcache.c += -fpie +CFLAGS-gai.c += -fpie $(objpfx)nscd: $(addprefix $(objpfx),$(nscd-modules:=.o)) $(LINK.o) -pie -Wl,-O1 \ -- cgit v1.1