aboutsummaryrefslogtreecommitdiff
path: root/posix/Makefile
diff options
context:
space:
mode:
authorStefan Liebler <stli@linux.ibm.com>2020-11-23 10:51:24 +0100
committerStefan Liebler <stli@linux.ibm.com>2020-11-23 10:51:24 +0100
commit29fddfc7dfd6444fa61a256e9a0d0127545e1f2e (patch)
tree01bb8ec6b2e22ae9397698b98a378129ab137cf2 /posix/Makefile
parent76ea70c613cee23a1846b9605e6433c1fa8baea7 (diff)
downloadglibc-29fddfc7dfd6444fa61a256e9a0d0127545e1f2e.tar
glibc-29fddfc7dfd6444fa61a256e9a0d0127545e1f2e.tar.gz
glibc-29fddfc7dfd6444fa61a256e9a0d0127545e1f2e.tar.bz2
glibc-29fddfc7dfd6444fa61a256e9a0d0127545e1f2e.zip
Use libnss_files.so for tests posix/bug-ga2 and resolv/tst-leaks2 [BZ #26821]
The tests posix/bug-ga2-mem and resolv/mtrace-tst-leaks2 are failing on fedora 33 as mtrace reports memory leaks. The /etc/nsswitch.conf differs between Fedora 32: hosts: files dns myhostname Fedora 33: hosts: files resolve [!UNAVAIL=return] myhostname dns Therefore /lib64/libnss_resolve.so.2 (from systemd) and the dependencies libgcc_s.so.1 and libpthread.so.0 are loaded. Usually all malloc'ed resources from getaddrinfo / gethostbyname are freed and the libraries are dlclose'd in nss/nsswitch.c:libc_freeres_fn (free_mem). Unfortunately, /lib64/libnss_resolve.so.2 is marked with DF_1_NODELETE. As this library is not unmapped, you'll see "Memory not freed". Therefore those tests are now only relying on libnss_files.so by making them test-container tests and providing the required configuration files. By moving the tests to tests-container, those are now running with "make check". Therefore the mtrace part of the tests are also moved from "make xcheck" to "make check". bug-ga2.c is now using test-driver.c in order to support WAIT_FOR_DEBUGGER environment variable.
Diffstat (limited to 'posix/Makefile')
-rw-r--r--posix/Makefile6
1 files changed, 3 insertions, 3 deletions
diff --git a/posix/Makefile b/posix/Makefile
index 693082ed28..fa2d0675cd 100644
--- a/posix/Makefile
+++ b/posix/Makefile
@@ -106,7 +106,8 @@ tests := test-errno tstgetopt testfnm runtests runptests \
tests-internal := bug-regex5 bug-regex20 bug-regex33 \
tst-rfc3484 tst-rfc3484-2 tst-rfc3484-3 \
tst-glob_lstat_compat tst-spawn4-compat
-xtests := bug-ga2 tst-getaddrinfo4 tst-getaddrinfo5
+tests-container := bug-ga2
+xtests := tst-getaddrinfo4 tst-getaddrinfo5
ifeq (yes,$(build-shared))
test-srcs := globtest
tests += wordexp-test tst-exec tst-spawn tst-spawn2 tst-spawn3
@@ -153,8 +154,7 @@ tests-special += $(objpfx)bug-regex2-mem.out $(objpfx)bug-regex14-mem.out \
$(objpfx)tst-boost-mem.out $(objpfx)tst-getconf.out \
$(objpfx)bug-glob2-mem.out $(objpfx)tst-vfork3-mem.out \
$(objpfx)tst-fnmatch-mem.out $(objpfx)bug-regex36-mem.out \
- $(objpfx)tst-glob-tilde-mem.out
-xtests-special += $(objpfx)bug-ga2-mem.out
+ $(objpfx)tst-glob-tilde-mem.out $(objpfx)bug-ga2-mem.out
endif
include ../Rules