Fix crash when entering static methods

Fixes #3590
This commit is contained in:
Jakub Valtar
2015-11-08 19:27:41 +01:00
parent bbbfea9129
commit 15b3a4718d

View File

@@ -920,7 +920,8 @@ public class Debugger implements VMEventListener {
if (!t.isSuspended() || t.frameCount() == 0) {
return "";
}
return t.frame(0).thisObject().referenceType().name();
ObjectReference ref = t.frame(0).thisObject();
return ref == null ? "" : ref.referenceType().name();
} catch (IncompatibleThreadStateException ex) {
log(Level.SEVERE, null, ex);