directory-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From seelm...@apache.org
Subject svn commit: r753020 - in /directory/studio/trunk/ldapbrowser-common/src/main/java/org/apache/directory/studio/ldapbrowser/common/wizards: NewEntryDnWizardPage.java NewEntryWizard.java
Date Thu, 12 Mar 2009 21:13:15 GMT
Author: seelmann
Date: Thu Mar 12 21:13:15 2009
New Revision: 753020

URL: http://svn.apache.org/viewvc?rev=753020&view=rev
Log:
Fixed a NullPointerException when no entry was selected

Modified:
    directory/studio/trunk/ldapbrowser-common/src/main/java/org/apache/directory/studio/ldapbrowser/common/wizards/NewEntryDnWizardPage.java
    directory/studio/trunk/ldapbrowser-common/src/main/java/org/apache/directory/studio/ldapbrowser/common/wizards/NewEntryWizard.java

Modified: directory/studio/trunk/ldapbrowser-common/src/main/java/org/apache/directory/studio/ldapbrowser/common/wizards/NewEntryDnWizardPage.java
URL: http://svn.apache.org/viewvc/directory/studio/trunk/ldapbrowser-common/src/main/java/org/apache/directory/studio/ldapbrowser/common/wizards/NewEntryDnWizardPage.java?rev=753020&r1=753019&r2=753020&view=diff
==============================================================================
--- directory/studio/trunk/ldapbrowser-common/src/main/java/org/apache/directory/studio/ldapbrowser/common/wizards/NewEntryDnWizardPage.java
(original)
+++ directory/studio/trunk/ldapbrowser-common/src/main/java/org/apache/directory/studio/ldapbrowser/common/wizards/NewEntryDnWizardPage.java
Thu Mar 12 21:13:15 2009
@@ -184,7 +184,7 @@
             String[] attributeNames = subschema.getAllAttributeNames();
 
             LdapDN parentDn = null;
-            if ( newEntry.getDn().equals( wizard.getSelectedEntry().getDn() )
+            if ( wizard.getSelectedEntry() != null && newEntry.getDn().equals( wizard.getSelectedEntry().getDn()
)
                 && DnUtils.getParent( newEntry.getDn() ) != null )
             {
                 parentDn = DnUtils.getParent( newEntry.getDn() );

Modified: directory/studio/trunk/ldapbrowser-common/src/main/java/org/apache/directory/studio/ldapbrowser/common/wizards/NewEntryWizard.java
URL: http://svn.apache.org/viewvc/directory/studio/trunk/ldapbrowser-common/src/main/java/org/apache/directory/studio/ldapbrowser/common/wizards/NewEntryWizard.java?rev=753020&r1=753019&r2=753020&view=diff
==============================================================================
--- directory/studio/trunk/ldapbrowser-common/src/main/java/org/apache/directory/studio/ldapbrowser/common/wizards/NewEntryWizard.java
(original)
+++ directory/studio/trunk/ldapbrowser-common/src/main/java/org/apache/directory/studio/ldapbrowser/common/wizards/NewEntryWizard.java
Thu Mar 12 21:13:15 2009
@@ -352,7 +352,7 @@
     /**
      * Gets the selected entry.
      * 
-     * @return the selected entry
+     * @return the selected entry, may be null
      */
     public IEntry getSelectedEntry()
     {



Mime
View raw message