fs: fchmod->fchown in promises/lchown
This was a clear error. chown should do chown, not chmod. PR-URL: https://github.com/nodejs/node/pull/20407 Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com> Reviewed-By: Tiancheng "Timothy" Gu <timothygu99@gmail.com> Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: Jamie Davis <davisjam@vt.edu> Reviewed-By: Sakthipriyan Vairamani <thechargingvolcano@gmail.com>
This commit is contained in:
parent
ca6b12e28d
commit
15f743165c
@ -390,7 +390,7 @@ async function lchown(path, uid, gid) {
|
||||
if (O_SYMLINK !== undefined) {
|
||||
const fd = await open(path,
|
||||
O_WRONLY | O_SYMLINK);
|
||||
return fchmod(fd, uid, gid).finally(fd.close.bind(fd));
|
||||
return fchown(fd, uid, gid).finally(fd.close.bind(fd));
|
||||
}
|
||||
throw new ERR_METHOD_NOT_IMPLEMENTED();
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user