mirror of
https://github.com/fergalmoran/ladybird.git
synced 2025-12-25 10:48:41 +00:00
Kernel: Allow sys$chmod() to change the sticky bit
We were incorrectly masking off the sticky bit when setting file modes.
This commit is contained in:
@@ -502,7 +502,7 @@ KResult VFS::chmod(Custody& custody, mode_t mode)
|
||||
return KResult(-EROFS);
|
||||
|
||||
// Only change the permission bits.
|
||||
mode = (inode.mode() & ~06777u) | (mode & 06777u);
|
||||
mode = (inode.mode() & ~07777u) | (mode & 07777u);
|
||||
return inode.chmod(mode);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user