summaryrefslogtreecommitdiff
path: root/src/user/app/iochk/iochk.c
diff options
context:
space:
mode:
authordzwdz2022-10-02 19:25:17 +0200
committerdzwdz2022-10-02 19:25:17 +0200
commit710e9b2b5c16f74f66420c66d12455ad518d42c7 (patch)
tree82b88cc07ef3f122512354d649af68584bd4da4d /src/user/app/iochk/iochk.c
parent503d9ff758f8b83295830bdfc8c2ea56837d25e5 (diff)
syscall/open: add the full suite of READ/WRITE flags
Diffstat (limited to 'src/user/app/iochk/iochk.c')
-rw-r--r--src/user/app/iochk/iochk.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/user/app/iochk/iochk.c b/src/user/app/iochk/iochk.c
index 38e0473..92975be 100644
--- a/src/user/app/iochk/iochk.c
+++ b/src/user/app/iochk/iochk.c
@@ -1,4 +1,5 @@
#include <assert.h>
+#include <camellia/flags.h>
#include <camellia/syscalls.h>
#include <stdbool.h>
#include <stdio.h>
@@ -84,7 +85,7 @@ int main(int argc, char **argv) {
for (; optind < argc; optind++) {
const char *path = argv[optind];
verbosef("checking %s...\n", path);
- handle_t h = _syscall_open(path, strlen(path), 0);
+ handle_t h = _syscall_open(path, strlen(path), OPEN_READ);
if (h < 0) {
eprintf("couldn't open %s", path);
continue;