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 255430 - NullPointerException at org.netbeans.modules.java.freeform.Classpaths.createExecuteClasspath
Summary: NullPointerException at org.netbeans.modules.java.freeform.Classpaths.createE...
Status: VERIFIED FIXED
Alias: None
Product: java
Classification: Unclassified
Component: Freeform (show other bugs)
Version: 8.1
Hardware: All All
: P3 normal (vote)
Assignee: Tomas Zezula
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2015-09-20 12:09 UTC by MackSix
Modified: 2015-09-24 13:04 UTC (History)
1 user (show)

See Also:
Issue Type: DEFECT
Exception Reporter: 220050


Attachments
stacktrace (1.92 KB, text/plain)
2015-09-20 12:09 UTC, MackSix
Details
stacktrace (1.92 KB, text/plain)
2015-09-20 12:45 UTC, MackSix
Details
Screenshot (249.40 KB, image/png)
2015-09-20 12:45 UTC, MackSix
Details

Note You need to log in before you can comment on or make changes to this bug.
Description MackSix 2015-09-20 12:09:19 UTC
Build: NetBeans IDE Dev (Build 201509200002)
VM: Java HotSpot(TM) 64-Bit Server VM, 25.60-b23, Java(TM) SE Runtime Environment, 1.8.0_60-b27
OS: Windows 7

User Comments:
MackSix: 1. Rand I&T If-Else Should Use Braces on JEdit 5.2 source code. 2. Afer inspection, the refactor preview window came up. 3. The first inspection showed the content of the file was to be completely removed. (Which is bogus) 4. I clicke the Refactor button. 5. After the Refactor, I clicked the Undo button on the toolbar. After that, I deleted the project from the Poject Window, including deleting the Project's folder on the hard drive. The project on the hard drive was not deleted, so I eleted it with Windows File Explorer. Everything was fine. 
5. I openend up a C++ projectd and compiled it. 
6. I then copied a backup of the JEdit project to the folder where I delete it and this happened.




Stacktrace: 
java.lang.NullPointerException
   at org.netbeans.modules.java.freeform.Classpaths.createExecuteClasspath(Classpaths.java:480)
   at org.netbeans.modules.java.freeform.Classpaths.access$500(Classpaths.java:126)
   at org.netbeans.modules.java.freeform.Classpaths$MutableClassPathImplementation.initRoots(Classpaths.java:605)
   at org.netbeans.modules.java.freeform.Classpaths$MutableClassPathImplementation.change(Classpaths.java:646)
   at org.netbeans.modules.java.freeform.Classpaths.pathsChanged(Classpaths.java:551)
   at org.netbeans.modules.java.freeform.Classpaths.configurationXmlChanged(Classpaths.java:535)
Comment 1 MackSix 2015-09-20 12:09:21 UTC
Created attachment 156305 [details]
stacktrace
Comment 2 MackSix 2015-09-20 12:45:02 UTC
Created attachment 156306 [details]
stacktrace

1. Ran I&T If-Else Should Use Braces on JEdit 5.2 source code. 2. Afer inspection, the refactor preview window came up. 3. The first inspection showed the content of the file was to be completely removed. (Which is bogus) 4. I clicked the Refactor button. 5. After the Refactor, I clicked the Undo button on the toolbar. 6. Then I clicked the Redo button. 7. After that, I deleted the project from the Poject Window, including deleting the Project's folder on the hard drive. This exception occured.
Comment 3 MackSix 2015-09-20 12:45:23 UTC
Created attachment 156307 [details]
Screenshot

Here is a screenshot showing the bogus refactor preview of the first file listed in the I&T preview. The preview shows the whole content of the file is to be deleted, but when I press the Refactor button, the content is not deleted. This is reproducible.
Comment 4 Tomas Zezula 2015-09-22 08:59:14 UTC
>Created attachment 156307 [details]
>Screenshot

>Here is a screenshot showing the bogus refactor preview of the first file listed in >the I&T preview. The preview shows the whole content of the file is to be deleted, but >when I press the Refactor button, the content is not deleted. This is reproducible.

Please create a separate issue on refactoring for this problem.

This issue is the NPE

Thanks
Comment 5 Tomas Zezula 2015-09-22 09:57:10 UTC
Fixed jet-main b54acd1da450
Comment 6 Quality Engineering 2015-09-24 01:29:38 UTC
Integrated into 'main-silver', will be available in build *201509240002* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)

Changeset: http://hg.netbeans.org/main-silver/rev/b54acd1da450
User: Tomas Zezula <tzezula@netbeans.org>
Log: #255430:NullPointerException at org.netbeans.modules.java.freeform.Classpaths.createExecuteClasspath
Comment 7 MackSix 2015-09-24 13:04:14 UTC
v. fixed.

Product Version: NetBeans IDE Dev (Build 201509240002)
Java: 1.8.0_60; Java HotSpot(TM) 64-Bit Server VM 25.60-b23
Runtime: Java(TM) SE Runtime Environment 1.8.0_60-b27
System: Windows 7 version 6.1 running on amd64; Cp1252; en_US (nb)