From 3540d66b669af54900b2e4bfc0ab82960e84a471 Mon Sep 17 00:00:00 2001 From: Andreas Schwab Date: Fri, 12 Nov 2010 03:51:28 -0500 Subject: Fix memory leak in fnmatch --- posix/Makefile | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) (limited to 'posix/Makefile') diff --git a/posix/Makefile b/posix/Makefile index 356896f..373e50b 100644 --- a/posix/Makefile +++ b/posix/Makefile @@ -115,7 +115,8 @@ generated := $(addprefix wordexp-test-result, 1 2 3 4 5 6 7 8 9 10) \ tst-rxspencer-mem tst-rxspencer.mtrace tst-getconf.out \ tst-pcre-mem tst-pcre.mtrace tst-boost-mem tst-boost.mtrace \ bug-ga2.mtrace bug-ga2-mem bug-glob2.mtrace bug-glob2-mem \ - tst-vfork3-mem tst-vfork3.mtrace getconf.speclist + tst-vfork3-mem tst-vfork3.mtrace getconf.speclist \ + tst-fnmatch-mem tst-fnmatch.mtrace include ../Rules @@ -235,7 +236,7 @@ ifeq (no,$(cross-compiling)) tests: $(objpfx)bug-regex2-mem $(objpfx)bug-regex14-mem \ $(objpfx)bug-regex21-mem $(objpfx)bug-regex31-mem $(objpfx)tst-rxspencer-mem\ $(objpfx)tst-pcre-mem $(objpfx)tst-boost-mem $(objpfx)tst-getconf.out \ - $(objpfx)bug-glob2-mem $(objpfx)tst-vfork3-mem + $(objpfx)bug-glob2-mem $(objpfx)tst-vfork3-mem $(objpfx)tst-fnmatch-mem xtests: $(objpfx)bug-ga2-mem endif @@ -247,6 +248,11 @@ annexc-CFLAGS = -O $(objpfx)annexc: annexc.c $(native-compile) +tst-fnmatch-ENV += MALLOC_TRACE=$(objpfx)tst-fnmatch.mtrace + +$(objpfx)tst-fnmatch-mem: $(objpfx)tst-fnmatch.out + $(common-objpfx)malloc/mtrace $(objpfx)tst-fnmatch.mtrace > $@ + bug-regex2-ENV = MALLOC_TRACE=$(objpfx)bug-regex2.mtrace $(objpfx)bug-regex2-mem: $(objpfx)bug-regex2.out -- cgit v1.1