summaryrefslogtreecommitdiff
path: root/src/regress/lib/libc/sys/t_write.c
diff options
context:
space:
mode:
authorbluhm <>2020-11-09 23:18:51 +0000
committerbluhm <>2020-11-09 23:18:51 +0000
commitc369d42df84f5bdabcac9041e6c5680a0cbfeaf9 (patch)
tree2233f16128b2705882f46a8369c9f9f47f40af5c /src/regress/lib/libc/sys/t_write.c
parent999ec352efbeb24cccd1d584b91a659b15764151 (diff)
downloadopenbsd-c369d42df84f5bdabcac9041e6c5680a0cbfeaf9.tar.gz
openbsd-c369d42df84f5bdabcac9041e6c5680a0cbfeaf9.tar.bz2
openbsd-c369d42df84f5bdabcac9041e6c5680a0cbfeaf9.zip
Sync libc syscall tests with changes in upstream NetBSD. Use #ifdef
to document differences to NetBSD behaviour, this helps to track upstream. Mark currently failing test as expected failures. So test programs get compiled and executed, but it shows that further investigation is necceassry.
Diffstat (limited to 'src/regress/lib/libc/sys/t_write.c')
-rw-r--r--src/regress/lib/libc/sys/t_write.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/regress/lib/libc/sys/t_write.c b/src/regress/lib/libc/sys/t_write.c
index f05edb5bed..326032db71 100644
--- a/src/regress/lib/libc/sys/t_write.c
+++ b/src/regress/lib/libc/sys/t_write.c
@@ -1,4 +1,4 @@
1/* $OpenBSD: t_write.c,v 1.2 2019/11/22 15:59:53 bluhm Exp $ */ 1/* $OpenBSD: t_write.c,v 1.3 2020/11/09 23:18:51 bluhm Exp $ */
2/* $NetBSD: t_write.c,v 1.7 2019/07/16 17:29:18 martin Exp $ */ 2/* $NetBSD: t_write.c,v 1.7 2019/07/16 17:29:18 martin Exp $ */
3 3
4/*- 4/*-
@@ -74,7 +74,7 @@ ATF_TC_BODY(write_err, tc)
74 errno = 0; 74 errno = 0;
75 ATF_REQUIRE_ERRNO(EBADF, write(-1, wbuf, sizeof(wbuf)) == -1); 75 ATF_REQUIRE_ERRNO(EBADF, write(-1, wbuf, sizeof(wbuf)) == -1);
76 76
77 fd = open(path, O_RDWR | O_CREAT); 77 fd = open(path, O_RDWR | O_CREAT, 0600);
78 78
79 if (fd >= 0) { 79 if (fd >= 0) {
80 80
@@ -146,7 +146,7 @@ ATF_TC_BODY(write_pos, tc)
146 size_t i; 146 size_t i;
147 int fd; 147 int fd;
148 148
149 fd = open(path, O_RDWR | O_CREAT); 149 fd = open(path, O_RDWR | O_CREAT, 0600);
150 ATF_REQUIRE(fd >= 0); 150 ATF_REQUIRE(fd >= 0);
151 151
152 for (i = 0; i < n; i++) { 152 for (i = 0; i < n; i++) {