Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorUwe Stieber2012-10-19 05:50:12 -0400
committerUwe Stieber2012-10-19 05:50:12 -0400
commita232abf9f70c0262a62b1a217f686c01e7fcd174 (patch)
tree7fcb0a046c1b42f76def51b69bc9714e7cf4d8a8 /target_explorer/plugins/org.eclipse.tcf.te.tcf.launch.core
parent0a50e94606f709ddbd68078cbbd0f6d192123d16 (diff)
downloadorg.eclipse.tcf-a232abf9f70c0262a62b1a217f686c01e7fcd174.tar.gz
org.eclipse.tcf-a232abf9f70c0262a62b1a217f686c01e7fcd174.tar.xz
org.eclipse.tcf-a232abf9f70c0262a62b1a217f686c01e7fcd174.zip
Target Explorer: Fix more NPE's found
Diffstat (limited to 'target_explorer/plugins/org.eclipse.tcf.te.tcf.launch.core')
-rw-r--r--target_explorer/plugins/org.eclipse.tcf.te.tcf.launch.core/src/org/eclipse/tcf/te/tcf/launch/core/internal/EventListenerDelegate.java2
-rw-r--r--target_explorer/plugins/org.eclipse.tcf.te.tcf.launch.core/src/org/eclipse/tcf/te/tcf/launch/core/lm/delegates/AttachLaunchManagerDelegate.java2
2 files changed, 2 insertions, 2 deletions
diff --git a/target_explorer/plugins/org.eclipse.tcf.te.tcf.launch.core/src/org/eclipse/tcf/te/tcf/launch/core/internal/EventListenerDelegate.java b/target_explorer/plugins/org.eclipse.tcf.te.tcf.launch.core/src/org/eclipse/tcf/te/tcf/launch/core/internal/EventListenerDelegate.java
index 66fd835b2..afaf287d5 100644
--- a/target_explorer/plugins/org.eclipse.tcf.te.tcf.launch.core/src/org/eclipse/tcf/te/tcf/launch/core/internal/EventListenerDelegate.java
+++ b/target_explorer/plugins/org.eclipse.tcf.te.tcf.launch.core/src/org/eclipse/tcf/te/tcf/launch/core/internal/EventListenerDelegate.java
@@ -57,7 +57,7 @@ public class EventListenerDelegate implements IEventListener {
if (contexts != null && contexts.length == 1 && contexts[0] instanceof IPeerModel && ((IPeerModel)contexts[0]).getPeerId().equalsIgnoreCase(peer.getID())) {
IPersistenceDelegate delegate = PersistenceManager.getInstance().getDelegate(Map.class, launchConfigAttributes, false);
try {
- Map<String, String> attributes = (Map<String,String>)delegate.read(Map.class, launchConfigAttributes, null);
+ Map<String, String> attributes = delegate != null ? (Map<String,String>)delegate.read(Map.class, launchConfigAttributes, null) : null;
if (attributes != null) {
attributes.remove(ILaunchContextLaunchAttributes.ATTR_LAUNCH_CONTEXTS);
attributes.remove(ICommonLaunchAttributes.ATTR_UUID);
diff --git a/target_explorer/plugins/org.eclipse.tcf.te.tcf.launch.core/src/org/eclipse/tcf/te/tcf/launch/core/lm/delegates/AttachLaunchManagerDelegate.java b/target_explorer/plugins/org.eclipse.tcf.te.tcf.launch.core/src/org/eclipse/tcf/te/tcf/launch/core/lm/delegates/AttachLaunchManagerDelegate.java
index 76d5b95d7..bab988fa3 100644
--- a/target_explorer/plugins/org.eclipse.tcf.te.tcf.launch.core/src/org/eclipse/tcf/te/tcf/launch/core/lm/delegates/AttachLaunchManagerDelegate.java
+++ b/target_explorer/plugins/org.eclipse.tcf.te.tcf.launch.core/src/org/eclipse/tcf/te/tcf/launch/core/lm/delegates/AttachLaunchManagerDelegate.java
@@ -121,7 +121,7 @@ public class AttachLaunchManagerDelegate extends DefaultLaunchManagerDelegate im
if (launchConfigAttributes != null) {
IPersistenceDelegate delegate = PersistenceManager.getInstance().getDelegate(Map.class, launchConfigAttributes, false);
try {
- Map<String, String> attributes = (Map<String,String>)delegate.read(Map.class, launchConfigAttributes, null);
+ Map<String, String> attributes = delegate != null ? (Map<String,String>)delegate.read(Map.class, launchConfigAttributes, null) : null;
if (attributes != null) {
attributes.remove(ILaunchContextLaunchAttributes.ATTR_LAUNCH_CONTEXTS);
attributes.remove(ICommonLaunchAttributes.ATTR_UUID);

Back to the top