Skip to main content
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJames Blackburn2009-11-24 09:02:59 -0500
committerJames Blackburn2009-11-24 09:02:59 -0500
commitca19a9fd5902f74ca1ef139e62513228716f4455 (patch)
tree5de41760defa2d228ffc457219f00dad8f08e6dd /debug/org.eclipse.cdt.debug.mi.core
parent193a63fe4e2b29180b02300349411145e042e30f (diff)
downloadorg.eclipse.cdt-ca19a9fd5902f74ca1ef139e62513228716f4455.tar.gz
org.eclipse.cdt-ca19a9fd5902f74ca1ef139e62513228716f4455.tar.xz
org.eclipse.cdt-ca19a9fd5902f74ca1ef139e62513228716f4455.zip
Bug 295988 Inability to create asynchronously created variable during update shouldn't break other variable updates
- Log CDIException during #processSuspendedEvent as this indicates something has broken.
Diffstat (limited to 'debug/org.eclipse.cdt.debug.mi.core')
-rw-r--r--debug/org.eclipse.cdt.debug.mi.core/cdi/org/eclipse/cdt/debug/mi/core/cdi/EventManager.java4
-rw-r--r--debug/org.eclipse.cdt.debug.mi.core/cdi/org/eclipse/cdt/debug/mi/core/cdi/VariableManager.java6
2 files changed, 8 insertions, 2 deletions
diff --git a/debug/org.eclipse.cdt.debug.mi.core/cdi/org/eclipse/cdt/debug/mi/core/cdi/EventManager.java b/debug/org.eclipse.cdt.debug.mi.core/cdi/org/eclipse/cdt/debug/mi/core/cdi/EventManager.java
index edd9793a3d..15e9078914 100644
--- a/debug/org.eclipse.cdt.debug.mi.core/cdi/org/eclipse/cdt/debug/mi/core/cdi/EventManager.java
+++ b/debug/org.eclipse.cdt.debug.mi.core/cdi/org/eclipse/cdt/debug/mi/core/cdi/EventManager.java
@@ -23,6 +23,7 @@ import org.eclipse.cdt.debug.core.cdi.event.ICDIEvent;
import org.eclipse.cdt.debug.core.cdi.event.ICDIEventListener;
import org.eclipse.cdt.debug.core.cdi.model.ICDIStackFrame;
import org.eclipse.cdt.debug.mi.core.MIException;
+import org.eclipse.cdt.debug.mi.core.MIPlugin;
import org.eclipse.cdt.debug.mi.core.MISession;
import org.eclipse.cdt.debug.mi.core.cdi.event.ChangedEvent;
import org.eclipse.cdt.debug.mi.core.cdi.event.CreatedEvent;
@@ -328,7 +329,8 @@ public class EventManager extends SessionObject implements ICDIEventManager, Obs
srcMgr.update(currentTarget);
}
} catch (CDIException e) {
- //System.out.println(e);
+ // Something went wrong => preventing updates to the model, this is serious
+ MIPlugin.log(e);
}
return true;
}
diff --git a/debug/org.eclipse.cdt.debug.mi.core/cdi/org/eclipse/cdt/debug/mi/core/cdi/VariableManager.java b/debug/org.eclipse.cdt.debug.mi.core/cdi/org/eclipse/cdt/debug/mi/core/cdi/VariableManager.java
index 7ea3c65409..f9f6e09c13 100644
--- a/debug/org.eclipse.cdt.debug.mi.core/cdi/org/eclipse/cdt/debug/mi/core/cdi/VariableManager.java
+++ b/debug/org.eclipse.cdt.debug.mi.core/cdi/org/eclipse/cdt/debug/mi/core/cdi/VariableManager.java
@@ -687,7 +687,11 @@ public class VariableManager extends Manager {
variable.setMIVarCreate(var);
update(target, variable, eventList);
} catch (MIException e) {
- throw new MI2CDIException(e);
+ // Creating failed, variable not in scope => remove
+ // No events to fire as the variable isn't backed by a MIVar
+ getVariablesList(target).remove(variable);
+ variable.setUpdated(false);
+ return;
} catch (CDIException e) {
throw e;
}

Back to the top