diff options
author | Sarika Sinha | 2020-07-29 07:22:00 +0000 |
---|---|---|
committer | Sarika Sinha | 2020-07-31 14:08:28 +0000 |
commit | f3c9dfacdaad75c9dcd62cf4b609f3f172fad3cf (patch) | |
tree | f489efb146235c0968dea28c2e4d21bc85198ec7 | |
parent | 78383e99825a9a02e2b832326b78501e985d9de8 (diff) | |
download | eclipse.jdt.debug-I20200731-1800.tar.gz eclipse.jdt.debug-I20200731-1800.tar.xz eclipse.jdt.debug-I20200731-1800.zip |
Change-Id: I4d6c3e7ac9d416a4c58c26c353438ccba3bf3b15
2 files changed, 9 insertions, 5 deletions
diff --git a/org.eclipse.jdt.launching/launching/org/eclipse/jdt/internal/launching/StandardVMDebugger.java b/org.eclipse.jdt.launching/launching/org/eclipse/jdt/internal/launching/StandardVMDebugger.java index e07c27baf..560961dca 100644 --- a/org.eclipse.jdt.launching/launching/org/eclipse/jdt/internal/launching/StandardVMDebugger.java +++ b/org.eclipse.jdt.launching/launching/org/eclipse/jdt/internal/launching/StandardVMDebugger.java @@ -1,5 +1,5 @@ /******************************************************************************* - * Copyright (c) 2000, 2019 IBM Corporation and others. + * Copyright (c) 2000, 2020 IBM Corporation and others. * * This program and the accompanying materials * are made available under the terms of the Eclipse Public License 2.0 @@ -36,6 +36,7 @@ import org.eclipse.core.runtime.Status; import org.eclipse.core.runtime.SubMonitor; import org.eclipse.debug.core.DebugPlugin; import org.eclipse.debug.core.ILaunch; +import org.eclipse.debug.core.ILaunchConfiguration; import org.eclipse.debug.core.IStatusHandler; import org.eclipse.debug.core.model.IDebugTarget; import org.eclipse.debug.core.model.IProcess; @@ -203,8 +204,11 @@ public class StandardVMDebugger extends StandardVMRunner { arguments.add("-Djava.compiler=NONE"); //$NON-NLS-1$ } // check if java 14 or greater - if (version >= 14) { - if (launch.getLaunchConfiguration().getAttribute(IJavaLaunchConfigurationConstants.ATTR_SHOW_CODEDETAILS_IN_EXCEPTION_MESSAGES, true)) { + ILaunchConfiguration launchConfiguration = launch.getLaunchConfiguration(); + // check if java 14 or greater + if (getJavaVersion(fVMInstance) >= 14) { + if (launchConfiguration != null + | launchConfiguration.getAttribute(IJavaLaunchConfigurationConstants.ATTR_SHOW_CODEDETAILS_IN_EXCEPTION_MESSAGES, true)) { arguments.add("-XX:+ShowCodeDetailsInExceptionMessages"); //$NON-NLS-1$ } } diff --git a/org.eclipse.jdt.launching/launching/org/eclipse/jdt/internal/launching/StandardVMRunner.java b/org.eclipse.jdt.launching/launching/org/eclipse/jdt/internal/launching/StandardVMRunner.java index f89b4c7ac..3ade6b747 100644 --- a/org.eclipse.jdt.launching/launching/org/eclipse/jdt/internal/launching/StandardVMRunner.java +++ b/org.eclipse.jdt.launching/launching/org/eclipse/jdt/internal/launching/StandardVMRunner.java @@ -1,5 +1,5 @@ /******************************************************************************* - * Copyright (c) 2000, 2019 IBM Corporation and others. + * Copyright (c) 2000, 2020 IBM Corporation and others. * * This program and the accompanying materials * are made available under the terms of the Eclipse Public License 2.0 @@ -444,7 +444,7 @@ public class StandardVMRunner extends AbstractVMRunner { // check if java 14 or greater if (getJavaVersion(fVMInstance) >= 14) { if (launchConfiguration != null - && launchConfiguration.getAttribute(IJavaLaunchConfigurationConstants.ATTR_SHOW_CODEDETAILS_IN_EXCEPTION_MESSAGES, true)) { + | launchConfiguration.getAttribute(IJavaLaunchConfigurationConstants.ATTR_SHOW_CODEDETAILS_IN_EXCEPTION_MESSAGES, true)) { arguments.add("-XX:+ShowCodeDetailsInExceptionMessages"); //$NON-NLS-1$ } } |