[hg] main-silver: #226407: Safe delete on @ProjectServiceProvide...

  • From: Martin Kozeny < >
  • To:
  • Subject: [hg] main-silver: #226407: Safe delete on @ProjectServiceProvide...
  • Date: Tue, 02 Apr 2013 10:25:05 -0700

changeset 787da079efba in main-silver ((none))
details: http://hg.netbeans.org/main-silver/rev/787da079efba
description:
        #226407: Safe delete on @ProjectServiceProvider now only handles with 
explicit layer.xml file (not with generated one). Eliminated NPE in 
AbstractRefactoringPlugin in method checkFileObject(), when passed FileObject 
is null.

diffstat:

 
apisupport.refactoring/src/org/netbeans/modules/apisupport/refactoring/AbstractRefactoringPlugin.java
 |  3 +++
 1 files changed, 3 insertions(+), 0 deletions(-)

diffs (20 lines):

diff --git 
a/apisupport.refactoring/src/org/netbeans/modules/apisupport/refactoring/AbstractRefactoringPlugin.java
 
b/apisupport.refactoring/src/org/netbeans/modules/apisupport/refactoring/AbstractRefactoringPlugin.java
--- 
a/apisupport.refactoring/src/org/netbeans/modules/apisupport/refactoring/AbstractRefactoringPlugin.java
+++ 
b/apisupport.refactoring/src/org/netbeans/modules/apisupport/refactoring/AbstractRefactoringPlugin.java
@@ -300,6 +300,8 @@
     
     
     private void checkFileObject(FileObject fo, String fqname, 
RefactoringElementsBag refactoringElements, LayerHandle handle) {
+        if(fo != null)
+        {
         if (fo.isFolder()) {
             FileObject[] childs = fo.getChildren();
             for (int i =0; i < childs.length; i++) {
@@ -379,6 +381,7 @@
             }
             
         }
+        }
         
     }
     

[hg] main-silver: #226407: Safe delete on @ProjectServiceProvide...

Martin Kozeny 04/02/2013

Project Features

About this Project

APIsupport was started in November 2009, is owned by Antonin Nebuzelsky, and has 64 members.
By use of this website, you agree to the NetBeans Policies and Terms of Use (revision 20150626.29986a4). © 2014, Oracle Corporation and/or its affiliates. Sponsored by Oracle logo
 
 
Close
loading
Please Confirm
Close