mirror of
https://github.com/eclipse-cdt/cdt
synced 2025-07-26 02:15:31 +02:00
Suspend does not work for solaris.
This commit is contained in:
parent
009f291ca4
commit
3f1e359697
2 changed files with 20 additions and 12 deletions
|
@ -6,7 +6,9 @@
|
|||
package org.eclipse.cdt.debug.mi.core.cdi;
|
||||
|
||||
import org.eclipse.cdt.debug.core.cdi.ICDIConfiguration;
|
||||
import org.eclipse.cdt.debug.mi.core.MIInferior;
|
||||
import org.eclipse.cdt.debug.mi.core.MISession;
|
||||
import org.eclipse.cdt.utils.spawner.Spawner;
|
||||
|
||||
/**
|
||||
* @author alain
|
||||
|
@ -94,13 +96,6 @@ public class Configuration implements ICDIConfiguration {
|
|||
return true;
|
||||
}
|
||||
|
||||
/**
|
||||
* @see org.eclipse.cdt.debug.core.cdi.ICDIConfiguration#supportsSuspendResume()
|
||||
*/
|
||||
public boolean supportsSuspendResume() {
|
||||
return true;
|
||||
}
|
||||
|
||||
/**
|
||||
* @see org.eclipse.cdt.debug.core.cdi.ICDIConfiguration#supportsTerminate()
|
||||
*/
|
||||
|
@ -119,6 +114,23 @@ public class Configuration implements ICDIConfiguration {
|
|||
* @see org.eclipse.cdt.debug.core.cdi.ICDIConfiguration#supportsSuspend()
|
||||
*/
|
||||
public boolean supportsSuspend() {
|
||||
String os = null;
|
||||
try {
|
||||
os = System.getProperty("os.name", "");
|
||||
} catch (SecurityException e) {
|
||||
}
|
||||
// FIXME: bug in gdb whe using -tty sending a control-c
|
||||
// to gdb does not work.
|
||||
if (os.equals("SunOS")) {
|
||||
return false;
|
||||
}
|
||||
Process gdb = miSession.getMIProcess();
|
||||
if (gdb instanceof Spawner) {
|
||||
MIInferior inferior = miSession.getMIInferior();
|
||||
if (inferior.getPTY() != null) {
|
||||
return true;
|
||||
}
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
|
|
|
@ -16,10 +16,6 @@ public class CoreFileConfiguration implements ICDIConfiguration {
|
|||
return false;
|
||||
}
|
||||
|
||||
public boolean supportsSuspendResume() {
|
||||
return false;
|
||||
}
|
||||
|
||||
public boolean supportsRestart() {
|
||||
return false;
|
||||
}
|
||||
|
@ -59,7 +55,7 @@ public class CoreFileConfiguration implements ICDIConfiguration {
|
|||
* @see org.eclipse.cdt.debug.core.cdi.ICDIConfiguration#supportsResume()
|
||||
*/
|
||||
public boolean supportsResume() {
|
||||
return true;
|
||||
return false;
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
Loading…
Add table
Reference in a new issue