Please use the Apache issue tracking system for new NetBeans issues (https://issues.apache.org/jira/projects/NETBEANS0/issues) !!

Bug 182343

Summary: NullPointerException at javax.imageio.ImageIO.write
Product: profiler Reporter: sunbiz <sunbiz>
Component: BaseAssignee: Jiri Sedlacek <jis>
Status: RESOLVED FIXED QA Contact: issues <issues.netbeans.org>
Priority: P3 CC: jkovalsky, sunbiz
Version: 6.xKeywords: NETFIX, SIMPLEFIX
Target Milestone: 6.x   
Hardware: All   
OS: All   
Whiteboard: EXCEPTIONS_REPORT
Issue Type: DEFECT Exception Report: 166665
Attachments: stacktrace
fixes NPE

Description sunbiz 2010-03-19 02:44:06 UTC
Build: NetBeans IDE Dev (Build 100319-48442a044a29)
VM: Java HotSpot(TM) Client VM, 14.3-b01, Java(TM) SE Runtime Environment, 1.6.0_17-b04
OS: Windows Server 2008

User Comments:
sunbiz: Took snapshot of thread dump. Saving current view as Image and select "Computer" instead of any drive or folder, throws this exception




Stacktrace: 
java.lang.NullPointerException
   at javax.imageio.ImageIO.write(ImageIO.java:1523)
   at org.netbeans.modules.profiler.SaveViewAction$1.run(SaveViewAction.java:210)
   at org.openide.util.RequestProcessor$Task.run(RequestProcessor.java:1356)
   at org.openide.util.RequestProcessor$Processor.run(RequestProcessor.java:1894)
Comment 1 sunbiz 2010-03-19 02:44:10 UTC
Created attachment 95407 [details]
stacktrace
Comment 2 sunbiz 2010-03-19 03:06:16 UTC
Should be simple to provide a fix through a correct error dialog as done in vmd.midp
Comment 3 sunbiz 2010-03-19 04:15:28 UTC
Created attachment 95410 [details]
fixes NPE
Comment 4 Jiri Kovalsky 2010-03-19 12:51:52 UTC
Jirko, can you please review the patch and integrate it if you find it good enough? Thanks!
Comment 5 Jiri Sedlacek 2010-03-22 16:07:42 UTC
Thanks for the patch! Applied with minor cleanup.

Fixed for 6.9, pushed into profiler-main.

http://hg.netbeans.org/profiler-main/rev/374a8ce6d493
Comment 6 Jiri Sedlacek 2010-03-22 16:14:29 UTC
More cleanup - http://hg.netbeans.org/profiler-main/rev/ed0c723acbab
Comment 7 Jiri Kovalsky 2010-03-22 21:07:34 UTC
Great, thank you Jirko for review&integration and Saptarshi for the patch!
Comment 8 sunbiz 2010-03-22 21:39:20 UTC
(In reply to comment #6)
> More cleanup - http://hg.netbeans.org/profiler-main/rev/ed0c723acbab

Thanks Jirko... and Jiri for the constant enthusiasm and support
Comment 9 Quality Engineering 2010-03-23 05:11:29 UTC
Integrated into 'main-golden', will be available in build *201003230200* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)
Changeset: http://hg.netbeans.org/main/rev/374a8ce6d493
User: Jiri Sedlacek <jis@netbeans.org>
Log: Bugfix #182343 - check for invalid target in SaveViewAction
By use of this website, you agree to the NetBeans Policies and Terms of Use. © 2014, Oracle Corporation and/or its affiliates. Sponsored by Oracle logo