You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@netbeans.apache.org by ma...@apache.org on 2020/03/06 18:21:48 UTC
[netbeans] branch master updated: [NETBEANS-2559] Avoid NPE when
openjfx
This is an automated email from the ASF dual-hosted git repository.
matthiasblaesing pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/netbeans.git
The following commit(s) were added to refs/heads/master by this push:
new 1ef6c46 [NETBEANS-2559] Avoid NPE when openjfx
new 02421e2 Merge pull request #2003 from errael/DebugOpenjfxWithoutNPE
1ef6c46 is described below
commit 1ef6c4665fa4b9b5da9a542937acdd9174188f24
Author: Ernie Rael <er...@raelity.com>
AuthorDate: Fri Mar 6 01:21:42 2020 +0000
[NETBEANS-2559] Avoid NPE when openjfx
---
.../modules/debugger/jpda/visual/VisualDebuggerListener.java | 6 +++++-
1 file changed, 5 insertions(+), 1 deletion(-)
diff --git a/java/debugger.jpda.visual/src/org/netbeans/modules/debugger/jpda/visual/VisualDebuggerListener.java b/java/debugger.jpda.visual/src/org/netbeans/modules/debugger/jpda/visual/VisualDebuggerListener.java
index 1aacc61..ed33601 100644
--- a/java/debugger.jpda.visual/src/org/netbeans/modules/debugger/jpda/visual/VisualDebuggerListener.java
+++ b/java/debugger.jpda.visual/src/org/netbeans/modules/debugger/jpda/visual/VisualDebuggerListener.java
@@ -459,6 +459,10 @@ public class VisualDebuggerListener extends DebuggerManagerAdapter {
*/
private static void setFxDebug(VirtualMachine vm, ThreadReference tr) {
ClassType sysPropClass = getClass(vm, tr, "com.sun.javafx.runtime.SystemProperties");
+ if(sysPropClass == null) {
+ // openjfx doesn't have runtime.SystemProperties.isDebug
+ return;
+ }
try {
Field debugFld = ReferenceTypeWrapper.fieldByName(sysPropClass, "isDebug"); // NOI18N
sysPropClass.setValue(debugFld, VirtualMachineWrapper.mirrorOf(vm, true));
@@ -474,7 +478,7 @@ public class VisualDebuggerListener extends DebuggerManagerAdapter {
if (t instanceof ClassType) {
return (ClassType)t;
}
- logger.log(Level.WARNING, "{0} is not a class but {1}", new Object[]{name, t}); // NOI18N
+ // logger.log(Level.WARNING, "{0} is not a class but {1}", new Object[]{name, t}); // NOI18N
return null;
}
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@netbeans.apache.org
For additional commands, e-mail: commits-help@netbeans.apache.org
For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists