From 4e7fd1ddaf4a04f3b38bbe5da76c57620025c9bb Mon Sep 17 00:00:00 2001 From: Alena Laskavaia Date: Thu, 13 Nov 2014 09:06:22 -0500 Subject: [PATCH] fixed NPE in DebugStringVariableSubstitutor when var cannot be resolved Change-Id: I5fe8f640e6dbf1673d32d6dec14aa2f9190a71de Signed-off-by: Alena Laskavaia Reviewed-on: https://git.eclipse.org/r/36405 Tested-by: Hudson CI Reviewed-by: Sergey Prigogin --- .../cdt/debug/internal/core/DebugStringVariableSubstitutor.java | 2 ++ 1 file changed, 2 insertions(+) diff --git a/debug/org.eclipse.cdt.debug.core/src/org/eclipse/cdt/debug/internal/core/DebugStringVariableSubstitutor.java b/debug/org.eclipse.cdt.debug.core/src/org/eclipse/cdt/debug/internal/core/DebugStringVariableSubstitutor.java index 86c1c70bcc9..3bc6980bf58 100644 --- a/debug/org.eclipse.cdt.debug.core/src/org/eclipse/cdt/debug/internal/core/DebugStringVariableSubstitutor.java +++ b/debug/org.eclipse.cdt.debug.core/src/org/eclipse/cdt/debug/internal/core/DebugStringVariableSubstitutor.java @@ -130,6 +130,8 @@ public class DebugStringVariableSubstitutor implements IStringVariableManager { public IDynamicVariable getDynamicVariable(String name) { IDynamicVariable var = variableManager.getDynamicVariable(name); + if (var == null) + return null; return substituteVariable(var); }