summaryrefslogtreecommitdiff
path: root/src/regress
diff options
context:
space:
mode:
Diffstat (limited to 'src/regress')
-rw-r--r--src/regress/lib/libc/sys/Makefile3
-rw-r--r--src/regress/lib/libc/sys/t_mmap.c10
2 files changed, 10 insertions, 3 deletions
diff --git a/src/regress/lib/libc/sys/Makefile b/src/regress/lib/libc/sys/Makefile
index 048d90186d..7dcfcb73a9 100644
--- a/src/regress/lib/libc/sys/Makefile
+++ b/src/regress/lib/libc/sys/Makefile
@@ -1,4 +1,4 @@
1# $OpenBSD: Makefile,v 1.8 2020/11/11 13:55:54 bluhm Exp $ 1# $OpenBSD: Makefile,v 1.9 2020/12/06 18:46:07 bluhm Exp $
2 2
3# Copyright (c) 2019 Moritz Buhl <openbsd@moritzbuhl.de> 3# Copyright (c) 2019 Moritz Buhl <openbsd@moritzbuhl.de>
4# Copyright (c) 2019 Alexander Bluhm <bluhm@openbsd.org> 4# Copyright (c) 2019 Alexander Bluhm <bluhm@openbsd.org>
@@ -48,7 +48,6 @@ PROGS += t_write
48# failing tests 48# failing tests
49REGRESS_EXPECTED_FAILURES = 49REGRESS_EXPECTED_FAILURES =
50REGRESS_EXPECTED_FAILURES += run-t_mlock-4 50REGRESS_EXPECTED_FAILURES += run-t_mlock-4
51REGRESS_EXPECTED_FAILURES += run-t_mmap-1
52REGRESS_EXPECTED_FAILURES += run-t_msgrcv-3 51REGRESS_EXPECTED_FAILURES += run-t_msgrcv-3
53REGRESS_EXPECTED_FAILURES += run-t_pipe2-2 52REGRESS_EXPECTED_FAILURES += run-t_pipe2-2
54REGRESS_EXPECTED_FAILURES += run-t_stat-5 53REGRESS_EXPECTED_FAILURES += run-t_stat-5
diff --git a/src/regress/lib/libc/sys/t_mmap.c b/src/regress/lib/libc/sys/t_mmap.c
index 9da88fa9cc..8d167cd5ec 100644
--- a/src/regress/lib/libc/sys/t_mmap.c
+++ b/src/regress/lib/libc/sys/t_mmap.c
@@ -1,4 +1,4 @@
1/* $OpenBSD: t_mmap.c,v 1.2 2020/11/09 23:18:51 bluhm Exp $ */ 1/* $OpenBSD: t_mmap.c,v 1.3 2020/12/06 18:46:07 bluhm Exp $ */
2/* $NetBSD: t_mmap.c,v 1.14 2020/06/26 07:50:11 jruoho Exp $ */ 2/* $NetBSD: t_mmap.c,v 1.14 2020/06/26 07:50:11 jruoho Exp $ */
3 3
4/*- 4/*-
@@ -175,14 +175,22 @@ ATF_TC_BODY(mmap_block, tc)
175 size_t len; 175 size_t len;
176 int fd = -1; 176 int fd = -1;
177 177
178#ifndef __OpenBSD__
179 /* works for us */
178 atf_tc_skip("The test case causes a panic " \ 180 atf_tc_skip("The test case causes a panic " \
179 "(PR kern/38889, PR kern/46592)"); 181 "(PR kern/38889, PR kern/46592)");
182#endif
180 183
181 ATF_REQUIRE(sysctl(mib, miblen, NULL, &len, NULL, 0) == 0); 184 ATF_REQUIRE(sysctl(mib, miblen, NULL, &len, NULL, 0) == 0);
182 drives = malloc(len); 185 drives = malloc(len);
183 ATF_REQUIRE(drives != NULL); 186 ATF_REQUIRE(drives != NULL);
184 ATF_REQUIRE(sysctl(mib, miblen, drives, &len, NULL, 0) == 0); 187 ATF_REQUIRE(sysctl(mib, miblen, drives, &len, NULL, 0) == 0);
188#ifdef __OpenBSD__
189 /* devices separated by comma, disk uid by colon */
190 for (dk = strtok(drives, ",:"); dk != NULL; dk = strtok(NULL, ",:")) {
191#else
185 for (dk = strtok(drives, " "); dk != NULL; dk = strtok(NULL, " ")) { 192 for (dk = strtok(drives, " "); dk != NULL; dk = strtok(NULL, " ")) {
193#endif
186 if (strncmp(dk, "dk", 2) == 0) 194 if (strncmp(dk, "dk", 2) == 0)
187 snprintf(dev, sizeof(dev), _PATH_DEV "%s", dk); 195 snprintf(dev, sizeof(dev), _PATH_DEV "%s", dk);
188 else 196 else