Skip to main content
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJohn Cortell2010-04-28 14:52:10 -0400
committerJohn Cortell2010-04-28 14:52:10 -0400
commit36de03adca08c8a348a12ce6efc1f6a314d9946d (patch)
treeee4df7e7e9cb57f0d9bb169236c11dac80ebc2dd /debug/org.eclipse.cdt.debug.mi.core
parent2c411b4045b242960705f74da8b79a46ae2f5a9a (diff)
downloadorg.eclipse.cdt-36de03adca08c8a348a12ce6efc1f6a314d9946d.tar.gz
org.eclipse.cdt-36de03adca08c8a348a12ce6efc1f6a314d9946d.tar.xz
org.eclipse.cdt-36de03adca08c8a348a12ce6efc1f6a314d9946d.zip
Adjustment to last commit. No need to make isAttached and isRemote mutually exclusive. CDI-GDB doesn't currently support attaching via gdbserver, but it's certainly possible (DSF-GDB supports it).
Diffstat (limited to 'debug/org.eclipse.cdt.debug.mi.core')
-rw-r--r--debug/org.eclipse.cdt.debug.mi.core/mi/org/eclipse/cdt/debug/mi/core/MIInferior.java17
-rw-r--r--debug/org.eclipse.cdt.debug.mi.core/src/org/eclipse/cdt/debug/mi/core/CygwinMIProcessAdapter.java2
-rw-r--r--debug/org.eclipse.cdt.debug.mi.core/src/org/eclipse/cdt/debug/mi/core/MIProcessAdapter.java4
3 files changed, 10 insertions, 13 deletions
diff --git a/debug/org.eclipse.cdt.debug.mi.core/mi/org/eclipse/cdt/debug/mi/core/MIInferior.java b/debug/org.eclipse.cdt.debug.mi.core/mi/org/eclipse/cdt/debug/mi/core/MIInferior.java
index 4a91e16a1e..d771005cbb 100644
--- a/debug/org.eclipse.cdt.debug.mi.core/mi/org/eclipse/cdt/debug/mi/core/MIInferior.java
+++ b/debug/org.eclipse.cdt.debug.mi.core/mi/org/eclipse/cdt/debug/mi/core/MIInferior.java
@@ -385,7 +385,7 @@ public class MIInferior extends Process {
/**
* Called early on in the debug session to mark the inferior process as being
- * under the control of a gdbserver.
+ * under the control of a gdbserver.
*
* @since 7.0
*/
@@ -394,8 +394,7 @@ public class MIInferior extends Process {
}
/**
- * Is the inferior process being debugged remotely through gdbserver? This
- * is mutually exclusive with {@link #isAttachedLocalInferior()}.
+ * Is the inferior process being debugged remotely through gdbserver?
*
* @since 7.0
*/
@@ -404,14 +403,12 @@ public class MIInferior extends Process {
}
/**
- * Is this inferior process being debugged through a local attach session?
- * I.e., is it a process running on "this" machine that was not launched by
- * gdb but which gdb attached to? This is mutually exclusive with
- * {@link #isRemoteInferior()
- *
- * @since 7.0
+ * Was the inferior process attached to by gdb (as opposed to launched by
+ * gdb).
+ *
+ * @since 7.0
*/
- public boolean isAttachedLocalInferior() {
+ public boolean isAttachedInferior() {
return session.isAttachSession();
}
}
diff --git a/debug/org.eclipse.cdt.debug.mi.core/src/org/eclipse/cdt/debug/mi/core/CygwinMIProcessAdapter.java b/debug/org.eclipse.cdt.debug.mi.core/src/org/eclipse/cdt/debug/mi/core/CygwinMIProcessAdapter.java
index 5308c3e218..68c670d3fa 100644
--- a/debug/org.eclipse.cdt.debug.mi.core/src/org/eclipse/cdt/debug/mi/core/CygwinMIProcessAdapter.java
+++ b/debug/org.eclipse.cdt.debug.mi.core/src/org/eclipse/cdt/debug/mi/core/CygwinMIProcessAdapter.java
@@ -57,7 +57,7 @@ public class CygwinMIProcessAdapter extends MIProcessAdapter {
// simulated Cygwin/POSIX SIGINT; a CTRL-C won't do.
gdbSpawner.interrupt();
}
- else if (inferior.isAttachedLocalInferior()) {
+ else if (inferior.isAttachedInferior()) {
// Cygwin gdb 6.8 has no support for forwarding an
// interrupt request to the local process it has
// attached to. That support has since been added and
diff --git a/debug/org.eclipse.cdt.debug.mi.core/src/org/eclipse/cdt/debug/mi/core/MIProcessAdapter.java b/debug/org.eclipse.cdt.debug.mi.core/src/org/eclipse/cdt/debug/mi/core/MIProcessAdapter.java
index 9c803f90bd..8f4cfcfbce 100644
--- a/debug/org.eclipse.cdt.debug.mi.core/src/org/eclipse/cdt/debug/mi/core/MIProcessAdapter.java
+++ b/debug/org.eclipse.cdt.debug.mi.core/src/org/eclipse/cdt/debug/mi/core/MIProcessAdapter.java
@@ -123,9 +123,9 @@ public class MIProcessAdapter implements MIProcess {
if (fGDBProcess instanceof Spawner) {
if (inferior.isRunning()) {
Spawner gdbSpawner = (Spawner) fGDBProcess;
- if (inferior.isAttachedLocalInferior()) {
+ if (inferior.isAttachedInferior() && !inferior.isRemoteInferior()) {
// not all gdb versions forward the interrupt to an attached
- // inferior, so interrupt the inferior directly
+ // local inferior, so interrupt the inferior directly
interruptInferior(inferior);
}
else {

Back to the top