git: 9d1eb47fa113 - main - stress2: Fix cleanup

Peter Holm pho at FreeBSD.org
Thu Sep 2 07:14:59 UTC 2021


The branch main has been updated by pho:

URL: https://cgit.FreeBSD.org/src/commit/?id=9d1eb47fa113d02f2082cf8104156e19484e75cf

commit 9d1eb47fa113d02f2082cf8104156e19484e75cf
Author:     Peter Holm <pho at FreeBSD.org>
AuthorDate: 2021-09-02 07:07:44 +0000
Commit:     Peter Holm <pho at FreeBSD.org>
CommitDate: 2021-09-02 07:07:44 +0000

    stress2: Fix cleanup
---
 tools/test/stress2/misc/mmap3.sh | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/tools/test/stress2/misc/mmap3.sh b/tools/test/stress2/misc/mmap3.sh
index 8a319377070f..56a64ee8cdee 100755
--- a/tools/test/stress2/misc/mmap3.sh
+++ b/tools/test/stress2/misc/mmap3.sh
@@ -42,13 +42,13 @@ while [ `date '+%s'` -lt $((start + 5 * 60)) ]; do
 	./mmap3
 done
 echo "Expect Segmentation faults"
-trap "ls /tmp/mmap3* | grep -E 'mmap3\.[0-9]{6}\.[0-9]{4}$' | xargs rm -v" \
-    EXIT INT
+trap "ls /tmp/mmap3* 2>/dev/null | grep -E 'mmap3\.[0-9]{6}\.[0-9]{4}$' | \
+    xargs rm -v" EXIT INT
 start=`date '+%s'`
 while [ `date '+%s'` -lt $((start + 5 * 60)) ]; do
 	./mmap3 random
 done
-rm -f mmap3 mmap3.core
+rm -f /tmp/mmap3 mmap3.core
 exit
 
 EOF


More information about the dev-commits-src-all mailing list