directory-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From akaras...@apache.org
Subject svn commit: r366057 - /directory/trunk/ldap-common/src/main/java/org/apache/ldap/common/codec/search/SearchResultEntry.java
Date Thu, 05 Jan 2006 02:12:28 GMT
Author: akarasulu
Date: Wed Jan  4 18:12:26 2006
New Revision: 366057

URL: http://svn.apache.org/viewcvs?rev=366057&view=rev
Log:
fixed bug where entry has attribute with no values and is not being properly encoded

Modified:
    directory/trunk/ldap-common/src/main/java/org/apache/ldap/common/codec/search/SearchResultEntry.java

Modified: directory/trunk/ldap-common/src/main/java/org/apache/ldap/common/codec/search/SearchResultEntry.java
URL: http://svn.apache.org/viewcvs/directory/trunk/ldap-common/src/main/java/org/apache/ldap/common/codec/search/SearchResultEntry.java?rev=366057&r1=366056&r2=366057&view=diff
==============================================================================
--- directory/trunk/ldap-common/src/main/java/org/apache/ldap/common/codec/search/SearchResultEntry.java
(original)
+++ directory/trunk/ldap-common/src/main/java/org/apache/ldap/common/codec/search/SearchResultEntry.java
Wed Jan  4 18:12:26 2006
@@ -239,6 +239,7 @@
             while ( attributes.hasMoreElements() )
             {
                 Attribute attribute = (Attribute)attributes.nextElement();
+                if ( attribute.size() == 0 ) continue;
                 int localAttributeLength = 0;
                 int localValuesLength = 0;
                 
@@ -360,6 +361,7 @@
                 while ( attributes.hasMoreElements() )
                 {
                     Attribute attribute = (Attribute)attributes.nextElement();
+                    if ( attribute.size() == 0 ) continue;
                     
                     // The partial attribute list sequence
                     buffer.put( UniversalTag.SEQUENCE_TAG );



Mime
View raw message