You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@directory.apache.org by el...@apache.org on 2006/01/28 18:51:30 UTC
svn commit: r373190 -
/directory/trunks/common/ldap/src/main/java/org/apache/ldap/common/codec/search/SearchResultEntry.java
Author: elecharny
Date: Sat Jan 28 09:51:26 2006
New Revision: 373190
URL: http://svn.apache.org/viewcvs?rev=373190&view=rev
Log:
Fixed the last fix ! The way empty attributes were encoded
was wrong ...
Modified:
directory/trunks/common/ldap/src/main/java/org/apache/ldap/common/codec/search/SearchResultEntry.java
Modified: directory/trunks/common/ldap/src/main/java/org/apache/ldap/common/codec/search/SearchResultEntry.java
URL: http://svn.apache.org/viewcvs/directory/trunks/common/ldap/src/main/java/org/apache/ldap/common/codec/search/SearchResultEntry.java?rev=373190&r1=373189&r2=373190&view=diff
==============================================================================
--- directory/trunks/common/ldap/src/main/java/org/apache/ldap/common/codec/search/SearchResultEntry.java (original)
+++ directory/trunks/common/ldap/src/main/java/org/apache/ldap/common/codec/search/SearchResultEntry.java Sat Jan 28 09:51:26 2006
@@ -94,6 +94,7 @@
public SearchResultEntry()
{
super( );
+ partialAttributeList = new BasicAttributes( true );
}
//~ Methods ------------------------------------------------------------------------------------
@@ -149,20 +150,6 @@
}
/**
- * Initialize the partial Attribute list if needed, otherwise add the current
- * Attribute Value to the list.
- *
- */
- public void addPartialAttributeList()
- {
-
- if ( currentAttributeValue == null )
- {
- partialAttributeList = new BasicAttributes( true );
- }
- }
-
- /**
* Create a new attributeValue
* @param type The attribute's name
*/
@@ -308,11 +295,6 @@
valsLength.add( new Integer( localValuesLength ) );
}
}
- else
- {
- // We do not have any attributes, so the SEQUENCE is empty : 0x30 0x00
- attributesLength = 1 + 1;
- }
searchResultEntryLength += 1 + Length.getNbBytes( attributesLength ) + attributesLength;
@@ -421,12 +403,6 @@
// Go to the next attribute number;
attributeNumber++;
}
- }
- else
- {
- // The empty partial attribute list sequence
- buffer.put( UniversalTag.SEQUENCE_TAG );
- buffer.put( (byte)0x00 );
}
}
catch ( BufferOverflowException boe )