This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 255373 - NPE thrown from a profiled NetBeans instance
Summary: NPE thrown from a profiled NetBeans instance
Status: RESOLVED FIXED
Alias: None
Product: profiler
Classification: Unclassified
Component: Engine (show other bugs)
Version: 8.1
Hardware: All All
: P3 normal (vote)
Assignee: Tomas Hurka
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2015-09-17 15:38 UTC by Jiri Sedlacek
Modified: 2016-09-03 02:14 UTC (History)
0 users

See Also:
Issue Type: DEFECT
Exception Reporter: 220001


Attachments
stacktrace (1.88 KB, text/plain)
2015-09-17 15:38 UTC, Jiri Sedlacek
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Jiri Sedlacek 2015-09-17 15:38:51 UTC
Build: NetBeans IDE Dev (Build 20150917-764af8e5db22)
VM: Java HotSpot(TM) 64-Bit Server VM, 25.45-b02, Java(TM) SE Runtime Environment, 1.8.0_45-b15
OS: Windows 7

User Comments:
jis: 1/ Start two NetBeans 8.1 instances, the profiling and profiled one
2/ Profiled NB: Open/create AnagramGame
3/ Profiling NB: Tools | Options | Java | Profiler | General | Enable manual setup for Methods and Objects
4/ Profiling NB: Attach to External Application, Objects, Defined classes, Classes 'java.lang.String', Track only live objects, unlimited allocations depth, click Attach
5/ Profiled NB: start AnagramGame using the Run action, wait until fully started, stop AnagramGame using the Stop button in Output window




Stacktrace: 
java.lang.NullPointerException
   at java.lang.Class$MethodArray.addAll(Class.java:2746)
   at java.lang.Class.privateGetPublicMethods(Class.java:2903)
   at java.lang.Class.getMethods(Class.java:1615)
   at org.apache.tools.ant.IntrospectionHelper.<init>(IntrospectionHelper.java:181)
   at org.apache.tools.ant.IntrospectionHelper.getHelper(IntrospectionHelper.java:351)
   at org.apache.tools.ant.IntrospectionHelper.getHelper(IntrospectionHelper.java:330)
Comment 1 Jiri Sedlacek 2015-09-17 15:38:54 UTC
Created attachment 156256 [details]
stacktrace
Comment 2 Jiri Sedlacek 2015-09-17 15:51:46 UTC
Caused: java.io.IOException: Could not load class org.apache.tools.ant.taskdefs.optional.image.Image: java.lang.NullPointerException.

Seems to be caused by the profiler, works fine when not being profiled.
Comment 3 Tomas Hurka 2016-09-01 11:24:56 UTC
Fixed in profiler-main

changeset:   299869:1c8be4ab93f4
user:        Tomas Hurka <thurka@netbeans.org>
date:        Thu Sep 01 11:30:13 2016 +0200
summary:     bugfix #255373, correctly handle java exception in vm_object_alloc()
Comment 4 Quality Engineering 2016-09-03 02:14:28 UTC
Integrated into 'main-silver', will be available in build *201609030002* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)

Changeset: http://hg.netbeans.org/main-silver/rev/1c8be4ab93f4
User: Tomas Hurka <thurka@netbeans.org>
Log: bugfix #255373, correctly handle java exception in vm_object_alloc()