mirror of
https://github.com/jart/cosmopolitan.git
synced 2025-05-24 06:12:27 +00:00
parent
95f54eeb40
commit
c1d99676c4
1421 changed files with 5556 additions and 2198 deletions
|
@ -19,10 +19,8 @@
|
|||
#include "libc/calls/internal.h"
|
||||
#include "libc/dce.h"
|
||||
#include "libc/errno.h"
|
||||
#include "libc/intrin/kprintf.h"
|
||||
#include "libc/macros.internal.h"
|
||||
#include "libc/runtime/gc.internal.h"
|
||||
#include "libc/str/str.h"
|
||||
#include "libc/sysv/consts/o.h"
|
||||
#include "libc/testlib/testlib.h"
|
||||
#include "libc/x/x.h"
|
||||
|
@ -30,7 +28,8 @@
|
|||
char testlib_enable_tmp_setup_teardown;
|
||||
|
||||
void SetUpOnce(void) {
|
||||
ASSERT_SYS(0, 0, pledge("stdio rpath wpath cpath fattr", 0));
|
||||
pledge("stdio rpath wpath cpath fattr", 0);
|
||||
errno = 0;
|
||||
}
|
||||
|
||||
TEST(open, efault) {
|
||||
|
@ -52,7 +51,7 @@ TEST(open, enotdir) {
|
|||
|
||||
TEST(open, eexist) {
|
||||
ASSERT_SYS(0, 0, touch("exists", 0644));
|
||||
ASSERT_SYS(EEXIST, -1, open("exists", O_WRONLY | O_CREAT | O_EXCL, 0644));
|
||||
ASSERT_SYS(EEXIST, -1, open("exists", O_WRONLY | O_CREAT | O_EXCL));
|
||||
}
|
||||
|
||||
TEST(open, doubleSlash_worksAndGetsNormalizedOnWindows) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue