diff options
author | Kaz Kylheku <kaz@kylheku.com> | 2020-02-07 20:33:58 -0800 |
---|---|---|
committer | Kaz Kylheku <kaz@kylheku.com> | 2020-02-07 20:33:58 -0800 |
commit | 9dddf656328b2bcd76292aabc44112e99ad1b25a (patch) | |
tree | e1f64bc6940fc7969fe8e03869db0a98b11f088e /sysif.c | |
parent | 3f229bc3ffd56da0742555d902cd3dce1697394b (diff) | |
download | txr-9dddf656328b2bcd76292aabc44112e99ad1b25a.tar.gz txr-9dddf656328b2bcd76292aabc44112e99ad1b25a.tar.bz2 txr-9dddf656328b2bcd76292aabc44112e99ad1b25a.zip |
chmod: fix broken Coreutils-compatible sticky clear.
* sysif.c (chmod_wrap): Clear the sticky bit from the right
variable: cmode rather than bits.
Diffstat (limited to 'sysif.c')
-rw-r--r-- | sysif.c | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -676,7 +676,7 @@ static val chmod_wrap(val target, val mode) case chm_set: cmode &= ~mask; if ((who & CHM_O) != 0) - bits &= ~S_ISVTX; /* GNU Coreutils 8.28 chmod behavior */ + cmode &= ~S_ISVTX; /* GNU Coreutils 8.28 chmod behavior */ if (!S_ISDIR(cmode)) cmode &= ~(S_ISUID | S_ISGID); cmode |= bits; |