mirror of
https://github.com/eclipse-cdt/cdt
synced 2025-08-11 02:05:39 +02:00
use getWorkingDirectory instead of getWorkingDir().
This commit is contained in:
parent
f7336ab6b8
commit
2526120966
1 changed files with 7 additions and 3 deletions
|
@ -80,9 +80,9 @@ public class LocalCLaunchConfigurationDelegate extends AbstractCLaunchDelegate {
|
||||||
dsession = debugConfig.getDebugger().createLaunchSession(config, exe);
|
dsession = debugConfig.getDebugger().createLaunchSession(config, exe);
|
||||||
ICDIRuntimeOptions opt = dsession.getRuntimeOptions();
|
ICDIRuntimeOptions opt = dsession.getRuntimeOptions();
|
||||||
opt.setArguments(getProgramArgumentsArray(config));
|
opt.setArguments(getProgramArgumentsArray(config));
|
||||||
File wd = getWorkingDir(config);
|
File wd = getWorkingDirectory(config);
|
||||||
if (wd != null) {
|
if (wd != null) {
|
||||||
opt.setWorkingDirectory(wd.toString());
|
opt.setWorkingDirectory(wd.getAbsolutePath());
|
||||||
}
|
}
|
||||||
opt.setEnvironment(getEnvironmentProperty(config));
|
opt.setEnvironment(getEnvironmentProperty(config));
|
||||||
ICDITarget dtarget = dsession.getTargets()[0];
|
ICDITarget dtarget = dsession.getTargets()[0];
|
||||||
|
@ -127,7 +127,11 @@ public class LocalCLaunchConfigurationDelegate extends AbstractCLaunchDelegate {
|
||||||
abort("Failed Launching CDI Debugger", e, ICDTLaunchConfigurationConstants.ERR_INTERNAL_ERROR);
|
abort("Failed Launching CDI Debugger", e, ICDTLaunchConfigurationConstants.ERR_INTERNAL_ERROR);
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
Process process = exec(commandArray, getEnvironmentArray(config), getWorkingDir(config));
|
File wd = getWorkingDirectory(config);
|
||||||
|
if (wd == null) {
|
||||||
|
wd = new File(System.getProperty("user.home", ".")); //NON-NLS-1;
|
||||||
|
}
|
||||||
|
Process process = exec(commandArray, getEnvironmentArray(config), wd);
|
||||||
DebugPlugin.getDefault().newProcess(launch, process, renderProcessLabel(commandArray[0]));
|
DebugPlugin.getDefault().newProcess(launch, process, renderProcessLabel(commandArray[0]));
|
||||||
}
|
}
|
||||||
monitor.done();
|
monitor.done();
|
||||||
|
|
Loading…
Add table
Reference in a new issue