summaryrefslogtreecommitdiff
path: root/Kernel/VirtualFileSystem.h
diff options
context:
space:
mode:
authorAndreas Kling <awesomekling@gmail.com>2019-01-29 04:55:08 +0100
committerAndreas Kling <awesomekling@gmail.com>2019-01-29 04:55:08 +0100
commitc30e2c8d440de7a8abbc1935cb5fb79b82d3421f (patch)
tree6ddae2118d2eec002f0327ff30d5a792828f3002 /Kernel/VirtualFileSystem.h
parentad53f6afd3de86fa927a2f8cdacdcbf5134af916 (diff)
downloadserenity-c30e2c8d440de7a8abbc1935cb5fb79b82d3421f.zip
Implement basic chmod() syscall and /bin/chmod helper.
Only raw octal modes are supported right now. This patch also changes mode_t from 32-bit to 16-bit to match the on-disk type used by Ext2FS. I also ran into EPERM being errno=0 which was confusing, so I inserted an ESUCCESS in its place.
Diffstat (limited to 'Kernel/VirtualFileSystem.h')
-rw-r--r--Kernel/VirtualFileSystem.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/Kernel/VirtualFileSystem.h b/Kernel/VirtualFileSystem.h
index 0832207956..23d9c37a96 100644
--- a/Kernel/VirtualFileSystem.h
+++ b/Kernel/VirtualFileSystem.h
@@ -69,6 +69,7 @@ public:
bool mkdir(const String& path, mode_t mode, InodeIdentifier base, int& error);
bool unlink(const String& path, Inode& base, int& error);
bool rmdir(const String& path, Inode& base, int& error);
+ bool chmod(const String& path, mode_t, Inode& base, int& error);
void register_character_device(CharacterDevice&);