Skip to content

Commit 466ef28

Browse files
committed
Fix UaM in node/process.c++
1 parent 23b7483 commit 466ef28

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/workerd/api/node/process.c++

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -182,7 +182,7 @@ void ProcessModule::setCwd(jsg::Lock& js, kj::String path) {
182182
if (statInfo.type != FsType::DIRECTORY) {
183183
node::THROW_ERR_UV_ENOTDIR(js, "chdir"_kj, nullptr, kj::str(resolvedPath));
184184
}
185-
if (!setCurrentWorkingDirectory(kj::mv(resolvedPath))) {
185+
if (!setCurrentWorkingDirectory(resolvedPath.clone())) {
186186
node::THROW_ERR_UV_EPERM(js, "chdir"_kj, nullptr, kj::str(resolvedPath));
187187
}
188188
}

0 commit comments

Comments
 (0)