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 188792

Summary: NullPointerException at java.io.DataOutputStream.writeUTF
Product: profiler Reporter: Alexandr Scherbatiy <sunflower>
Component: BaseAssignee: issues@profiler <issues>
Status: RESOLVED FIXED    
Severity: normal Keywords: VISUALVM
Priority: P3    
Version: 6.x   
Hardware: All   
OS: All   
Issue Type: DEFECT Exception Reporter: 171467
Attachments: stacktrace

Description Alexandr Scherbatiy 2010-07-20 12:42:24 UTC
This issue was reported manually by sunflower.
It already has 1 duplicates 


Build: NetBeans IDE 6.9.1 Dev (Build 201007182301)
VM: Java HotSpot(TM) Client VM, 16.3-b01, Java(TM) SE Runtime Environment, 1.6.0_20-b02
OS: Windows XP

Stacktrace: 
java.lang.NullPointerException
   at java.io.DataOutputStream.writeUTF(DataOutputStream.java:330)
   at java.io.DataOutputStream.writeUTF(DataOutputStream.java:306)
   at org.netbeans.lib.profiler.results.memory.JMethodIdTable.writeToStream(JMethodIdTable.java:187)
   at org.netbeans.lib.profiler.results.memory.MemoryResultsSnapshot.writeToStream(MemoryResultsSnapshot.java:275)
   at org.netbeans.lib.profiler.results.memory.AllocMemoryResultsSnapshot.writeToStream(AllocMemoryResultsSnapshot.java:122)
   at org.netbeans.modules.profiler.LoadedSnapshot.save(LoadedSnapshot.java:287)
Comment 1 Alexandr Scherbatiy 2010-07-20 12:42:30 UTC
Created attachment 100934 [details]
stacktrace
Comment 2 J Bachorik 2010-10-06 15:06:46 UTC
Adding a proper and consistent synchronization for accessing internal data in JMethodIdTable - should prevent race condition caused NPE

http://hg.netbeans.org/profiler-main/rev/cafdcfe1df0f
Comment 3 Quality Engineering 2010-10-09 15:26:14 UTC
Integrated into 'main-golden', will be available in build *201010090000* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)
Changeset: http://hg.netbeans.org/main/rev/cafdcfe1df0f
User: Jaroslav Bachorik <yardus@netbeans.org>
Log: #188792 - Synchronizing changes of the internal structures of JMethodIdTable consistently - should prevent a NPE caused by race condition