directory-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From seelm...@apache.org
Subject svn commit: r821718 - /directory/studio/trunk/ldapbrowser-ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/editors/searchresult/SearchResultEditor.java
Date Mon, 05 Oct 2009 08:28:54 GMT
Author: seelmann
Date: Mon Oct  5 08:28:54 2009
New Revision: 821718

URL: http://svn.apache.org/viewvc?rev=821718&view=rev
Log:
Fixed NullPointerException

Modified:
    directory/studio/trunk/ldapbrowser-ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/editors/searchresult/SearchResultEditor.java

Modified: directory/studio/trunk/ldapbrowser-ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/editors/searchresult/SearchResultEditor.java
URL: http://svn.apache.org/viewvc/directory/studio/trunk/ldapbrowser-ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/editors/searchresult/SearchResultEditor.java?rev=821718&r1=821717&r2=821718&view=diff
==============================================================================
--- directory/studio/trunk/ldapbrowser-ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/editors/searchresult/SearchResultEditor.java
(original)
+++ directory/studio/trunk/ldapbrowser-ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/editors/searchresult/SearchResultEditor.java
Mon Oct  5 08:28:54 2009
@@ -130,12 +130,15 @@
                 if ( input instanceof SearchResultEditorInput )
                 {
                     SearchResultEditorInput srei = ( SearchResultEditorInput ) input;
-                    for ( ISearchResult sr : srei.getSearch().getSearchResults() )
+                    if ( srei.getSearch() != null && srei.getSearch().getSearchResults()
!= null )
                     {
-                        if ( modifiedEntry == sr.getEntry() )
+                        for ( ISearchResult sr : srei.getSearch().getSearchResults() )
                         {
-                            // original entry has been updated, update widget input
-                            setSearchResultEditorWidgetInput( srei );
+                            if ( modifiedEntry == sr.getEntry() )
+                            {
+                                // original entry has been updated, update widget input
+                                setSearchResultEditorWidgetInput( srei );
+                            }
                         }
                     }
                 }



Mime
View raw message