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.
Steps: 0/ Disable marker methods for Java SE (comment out content of mf-layer.xml) 1/ Create AnagramGame 2/ Insert Reset Results profiling point in com.toy.anagrams.ui.Anagrams:261 3/ CPU, Advanced, Customize, select com.toy.anagrams.ui.Anagrams$2 ~ $5, Profile only project classes 4/ Start profiling The following exception is thrown by the profiled app: java.lang.NullPointerException at org.netbeans.lib.profiler.global.ProfilingSessionStatus.updateInstrMethodsInfo(ProfilingSessionStatus.java:373) at org.netbeans.lib.profiler.server.ProfilerInterface.updateInstrClassAndMethodNames(ProfilerInterface.java:1347) at org.netbeans.lib.profiler.server.ProfilerInterface.getAndInstrumentClasses(ProfilerInterface.java:677) at org.netbeans.lib.profiler.server.ProfilerInterface.classLoadHook(ProfilerInterface.java:946) at com.toy.anagrams.ui.Anagrams.initComponents(Anagrams.java:172) at com.toy.anagrams.ui.Anagrams.<init>(Anagrams.java:80) at com.toy.anagrams.ui.Anagrams.main(Anagrams.java:70)
Created attachment 124511 [details] fix The first server-side call to updateInstrMethodsInfo() with nMethods=0 result in nInstrMethods=1 and instrMethodInvoked=null. Which breaks class invariant and produce NPE in subsequent calls to the updateInstrMethodsInfo() method.
fixed in: http://hg.netbeans.org/profiler-main/rev/111007aa602b
Integrated into 'main-golden', will be available in build *201209210001* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress) Changeset: http://hg.netbeans.org/main-golden/rev/111007aa602b User: Jan Taus <jtau8042@netbeans.org> Log: #212492: NPE in ProfilingSessionStatus.updateInstrMethodsInfo