Skip to content

Commit

Permalink
fix: add condition for existence of current_dir (#995)
Browse files Browse the repository at this point in the history
  • Loading branch information
jaeheonji authored Jan 9, 2022
1 parent 690af2e commit d2cfcb3
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion zellij-server/src/os_input_output.rs
Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,9 @@ fn handle_openpty(
let mut child = unsafe {
let command = &mut Command::new(cmd.command);
if let Some(current_dir) = cmd.cwd {
command.current_dir(current_dir);
if current_dir.exists() {
command.current_dir(current_dir);
}
}
command
.args(&cmd.args)
Expand Down

0 comments on commit d2cfcb3

Please sign in to comment.