diff options
author | Anton Kling <anton@kling.gg> | 2023-11-15 21:13:36 +0100 |
---|---|---|
committer | Anton Kling <anton@kling.gg> | 2023-11-15 22:11:26 +0100 |
commit | 835101f96e7c9fca00940e967c471c33e4e4dae9 (patch) | |
tree | 9c48b871d4b547fac8c3a2eda6c21242e593fdfd /userland/libc/unistd | |
parent | c9358cdeac4522922df46fb6e3ab6a517203ec99 (diff) |
VFS/LibC: Add getcwd()
Diffstat (limited to 'userland/libc/unistd')
-rw-r--r-- | userland/libc/unistd/getcwd.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/userland/libc/unistd/getcwd.c b/userland/libc/unistd/getcwd.c new file mode 100644 index 0000000..6050c95 --- /dev/null +++ b/userland/libc/unistd/getcwd.c @@ -0,0 +1,6 @@ +#include <syscall.h> +#include <unistd.h> + +char *getcwd(char *buf, size_t size) { + return syscall(SYS_GETCWD, buf, size, NULL, NULL, NULL); +} |