]> git.ipfire.org Git - thirdparty/valgrind.git/commitdiff
Adjust filter_fdleak for glibc debuginfo
authorMark Wielaard <mark@klomp.org>
Fri, 15 Mar 2024 12:03:58 +0000 (13:03 +0100)
committerMark Wielaard <mark@klomp.org>
Fri, 15 Mar 2024 12:06:14 +0000 (13:06 +0100)
With glibc debuginfo installed we might see syscal-template.S or
close.c replace that with "in ...libc...".

none/tests/filter_fdleak

index 7258bc7993ad53a2ae02223efa769fda3d38e3bb..f7637abd015e759f2122f7dfb387fb61e1e96102 100755 (executable)
@@ -25,6 +25,8 @@ perl -p -e 's/ _close / close /;s/ _openat / creat /;s/internet/AF_INET socket 4
 # So we just cut out the entire stack trace.  It's coarse but effective;
 # before we did this we had a plethora of expected outputs, with only
 # painfully minor variations between them.
-perl -p -0 -e 's/(Open[^\n]*\n)(   (at|by)[^\n]*\n)+/$1   ...\n/gs'
-
+perl -p -0 -e 's/(Open[^\n]*\n)(   (at|by)[^\n]*\n)+/$1   ...\n/gs' |
 
+# With glibc debuginfo installed we might see syscal-template.S or close.c
+perl -p -e "s/\(syscall-template.S:[0-9]*\)/(in \/...libc...)/" |
+perl -p -e "s/\(close.c:[0-9]*\)/(in \/...libc...)/"