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 235500 - NullPointerException at org.netbeans.modules.j2ee.ejbrefactoring.EjbRefactoringPlugin$1.run
Summary: NullPointerException at org.netbeans.modules.j2ee.ejbrefactoring.EjbRefactori...
Status: VERIFIED FIXED
Alias: None
Product: javaee
Classification: Unclassified
Component: EJB (show other bugs)
Version: 7.4
Hardware: All All
: P2 normal (vote)
Assignee: Martin Fousek
URL:
Keywords: 7.4_HR_FIX
Depends on:
Blocks:
 
Reported: 2013-09-04 12:13 UTC by ssazonov
Modified: 2013-09-17 11:56 UTC (History)
2 users (show)

See Also:
Issue Type: DEFECT
Exception Reporter: 203569


Attachments
stacktrace (2.19 KB, text/plain)
2013-09-04 12:13 UTC, ssazonov
Details
stacktrace (2.19 KB, text/plain)
2013-09-09 16:02 UTC, aldobrucale
Details

Note You need to log in before you can comment on or make changes to this bug.
Description ssazonov 2013-09-04 12:13:58 UTC
Build: NetBeans IDE Dev (Build 201308300001)
VM: Java HotSpot(TM) 64-Bit Server VM, 24.0-b55, Java(TM) SE Runtime Environment, 1.7.0_40-b39
OS: Windows 7

User Comments:
ssazonov: I tried to introduce parameter and get this error




Stacktrace: 
java.lang.NullPointerException
   at org.netbeans.modules.j2ee.ejbrefactoring.EjbRefactoringPlugin$1.run(EjbRefactoringPlugin.java:106)
   at org.netbeans.modules.j2ee.ejbrefactoring.EjbRefactoringPlugin$1.run(EjbRefactoringPlugin.java:101)
   at org.netbeans.api.java.source.JavaSource$MultiTask.run(JavaSource.java:493)
   at org.netbeans.modules.parsing.impl.TaskProcessor.callUserTask(TaskProcessor.java:593)
   at org.netbeans.modules.parsing.api.ParserManager$UserTaskAction.run(ParserManager.java:155)
   at org.netbeans.modules.parsing.api.ParserManager$UserTaskAction.run(ParserManager.java:139)
Comment 1 ssazonov 2013-09-04 12:13:59 UTC
Created attachment 139652 [details]
stacktrace
Comment 2 ssazonov 2013-09-04 12:27:38 UTC
I tried again to introduce parameter on "aaa" and got same error:


/*
 * To change this license header, choose License Headers in Project Properties.
 * To change this template file, choose Tools | Templates
 * and open the template in the editor.
 */

package simpleproject123;


/**
 <p>
 @author Standa
 */
public class SimpleProject123 {


	/**
	 @param args the command line arguments
	 */
	public static void main(String[] args){
		// TODO code application logic here
		m();
	}
	
	static void m(){
		if(true){
			System.out.println("aaa");
		}
	}
	
}
Comment 3 aldobrucale 2013-09-09 16:02:57 UTC
Created attachment 139845 [details]
stacktrace

introduce parameter refactoring (in a plain java se project)
Comment 4 Martin Fousek 2013-09-10 06:14:28 UTC
It looks that some duplicates of this NPE are comming. I took a look into the source and this could be a regression in refactoring of sources mentioned by reporters. Vlado do you agree wtih marking this issue as a nb74 HR candidate? The fix should be safe and easy.
Comment 5 Vladimir Riha 2013-09-10 07:25:20 UTC
Sure, I agree. Raising priority and adding keyword...
Comment 6 Martin Fousek 2013-09-10 11:32:49 UTC
Fixed in web-main #29f9c0e8c6e9.

Martine, could I ask you for the review? Thanks in advance.
Comment 7 Martin Janicek 2013-09-10 11:39:39 UTC
The patch looks definitely safe and fine
Comment 8 Vladimir Riha 2013-09-11 12:18:12 UTC
Verified in web main build, please continue with integration

Product Version: NetBeans IDE Dev (Build web-main-11581-on-20130911)
Java: 1.7.0_40; Java HotSpot(TM) Client VM 24.0-b56
Runtime: Java(TM) SE Runtime Environment 1.7.0_40-b43
System: Linux version 3.2.0-48-generic-pae running on i386; UTF-8; en_US (nb)
Comment 9 Martin Fousek 2013-09-11 12:27:46 UTC
(In reply to Vladimir Riha from comment #8)
> Verified in web main build, please continue with integration

Thanks for the verification.

Integrated into the release74 branch as releases #747378c2fbe8.
Comment 10 ssazonov 2013-09-17 11:56:21 UTC
Verified:

Product Version: NetBeans IDE 7.4 RC1 (Build 201309152201)
Java: 1.7.0_40; Java HotSpot(TM) Client VM 24.0-b56
Runtime: Java(TM) SE Runtime Environment 1.7.0_40-b43
System: Windows 7 version 6.1 running on x86; Cp1252; en_US (nb)