diff --git a/platform/platform-api/src/com/intellij/execution/configurations/GeneralCommandLine.java b/platform/platform-api/src/com/intellij/execution/configurations/GeneralCommandLine.java index 8f54a0d6de81..cfca24a6ae35 100644 --- a/platform/platform-api/src/com/intellij/execution/configurations/GeneralCommandLine.java +++ b/platform/platform-api/src/com/intellij/execution/configurations/GeneralCommandLine.java @@ -278,7 +278,7 @@ public class GeneralCommandLine implements UserDataHolder { if (myRedirectErrorStream) { LOG.error("Launching process with PTY and redirected error stream is unsupported yet"); } - return PtyProcess.exec(ArrayUtil.toStringArray(commands), env, myWorkDirectory.getPath(), true); + return PtyProcess.exec(ArrayUtil.toStringArray(commands), env, myWorkDirectory != null? myWorkDirectory.getPath() : null, true); } private Process startProcess(List commands) throws IOException {