From 02062f0cf84e1cb7fb294de54b0c00db6323c529 Mon Sep 17 00:00:00 2001 From: Nathan Reiner Date: Thu, 15 Dec 2022 21:17:41 +0100 Subject: add 'cd' to smash --- lib/sys/chdir.h | 11 +++++++++++ 1 file changed, 11 insertions(+) create mode 100644 lib/sys/chdir.h (limited to 'lib') diff --git a/lib/sys/chdir.h b/lib/sys/chdir.h new file mode 100644 index 0000000..497698f --- /dev/null +++ b/lib/sys/chdir.h @@ -0,0 +1,11 @@ +#ifndef CHDIR_H +#define CHDIR_H + +#include "syscalls.h" + +static int chdir(const char *filename) +{ + return syscall(CHDIR, filename); +} + +#endif -- cgit v1.2.3-70-g09d2