fn processSetCurrentPath(userdata: ?*anyopaque, dir_path: []const u8) process.SetCurrentPathError!void
fn processSetCurrentPath(userdata: ?*anyopaque, dir_path: []const u8) process.SetCurrentPathError!void { const ev: *Evented = @ptrCast(@alignCast(userdata)); var path_buffer: [PATH_MAX]u8 = undefined; const dir_path_posix = try pathToPosix(dir_path, &path_buffer); var sync: CancelRegion.Sync = try .init(ev); defer sync.deinit(ev); return chdir(&sync, dir_path_posix); }