From d4d3a3c54f5e26dec0cc79e273dc488f8a47f2b3 Mon Sep 17 00:00:00 2001 From: Nathan Whitaker <17734409+nathanwhit@users.noreply.github.com> Date: Fri, 5 Jul 2024 11:32:51 -0700 Subject: fix(node): Implement `fs.lchown` (and `process.getegid`) (#24418) Closes https://github.com/denoland/deno/issues/21260. Part of https://github.com/denoland/deno/issues/18218. Implements `node:fs.lchown`, and enables the node_compat test for it. The test uses `process.getegid`, which we didn't have implemented, so I went ahead and implemented that as well to get the test working. --- runtime/permissions/lib.rs | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'runtime/permissions/lib.rs') diff --git a/runtime/permissions/lib.rs b/runtime/permissions/lib.rs index 4579eba1a..3b3f68a53 100644 --- a/runtime/permissions/lib.rs +++ b/runtime/permissions/lib.rs @@ -915,7 +915,9 @@ impl Descriptor for SysDescriptor { pub fn parse_sys_kind(kind: &str) -> Result<&str, AnyError> { match kind { "hostname" | "osRelease" | "osUptime" | "loadavg" | "networkInterfaces" - | "systemMemoryInfo" | "uid" | "gid" | "cpus" | "homedir" => Ok(kind), + | "systemMemoryInfo" | "uid" | "gid" | "cpus" | "homedir" | "getegid" => { + Ok(kind) + } _ => Err(type_error(format!("unknown system info kind \"{kind}\""))), } } -- cgit v1.2.3