Issue Details (XML | Word | Printable)

Key: DIRSERVER-743
Type: Bug Bug
Status: Closed Closed
Resolution: Fixed
Priority: Major Major
Assignee: Emmanuel Lecharny
Reporter: Alex Karasulu
Votes: 0
Watchers: 0
Operations

If you were logged in you would be able to see more operations.
Directory ApacheDS

Carriage return after header comments makes LdifReader fail

Created: 17/Sep/06 11:21 PM   Updated: 02/Oct/06 01:43 PM
Return to search
Component/s: None
Affects Version/s: None
Fix Version/s: None

Time Tracking:
Not Specified

File Attachments:
  Size
File Licensed for inclusion in ASF works test.ldif 2006-09-17 11:24 PM Alex Karasulu 1 kB

Resolution Date: 18/Sep/06 08:50 AM


 Description  « Hide
A carriage return after a header in an Ldif makes the LdifReader fail. Just as an example try the attached LDIF file.

 All   Comments   Work Log   Change History   Subversion Commits      Sort Order: Ascending order - Click to sort in descending order
Alex Karasulu added a comment - 17/Sep/06 11:24 PM
Notice the extra carriage return in the file after the header comment right before the only entry in the ldif.

Alex Karasulu made changes - 17/Sep/06 11:24 PM
Field Original Value New Value
Attachment test.ldif [ 12341014 ]
Emmanuel Lecharny made changes - 18/Sep/06 06:50 AM
Assignee Emmanuel Lecharny [ elecharny ]
Emmanuel Lecharny added a comment - 18/Sep/06 08:50 AM
The flag used to mark the first entry was badly positionned. In case we had comments before any entry, it was unset, and the parser thought that the first newline was the first -empty- entry.

Fixed.

Emmanuel Lecharny made changes - 18/Sep/06 08:50 AM
Resolution Fixed [ 1 ]
Status Open [ 1 ] Resolved [ 5 ]
Repository Revision Date User Message
ASF #447322 Mon Sep 18 08:50:23 UTC 2006 elecharny Fixed DIRSERVER-743 : the isFirstLine flag was unset in the wrong place.
Files Changed
MODIFY /directory/branches/shared/0.9.5/ldap/src/main/java/org/apache/directory/shared/ldap/ldif/LdifReader.java

Repository Revision Date User Message
ASF #447323 Mon Sep 18 08:50:47 UTC 2006 elecharny Added a test to check DIRSERVER-743
Files Changed
MODIFY /directory/branches/shared/0.9.5/ldap/src/test/java/org/apache/directory/shared/ldap/ldif/LdifReaderTest.java

Repository Revision Date User Message
ASF #447345 Mon Sep 18 09:50:20 UTC 2006 elecharny Applied patch for DIRSERVER-743 in trunks
Files Changed
MODIFY /directory/trunks/shared/ldap/src/main/java/org/apache/directory/shared/ldap/ldif/LdifReader.java
MODIFY /directory/trunks/shared/ldap/src/test/java/org/apache/directory/shared/ldap/ldif/LdifReaderTest.java

Alex Karasulu added a comment - 02/Oct/06 01:43 PM
fixed and confirmed

Alex Karasulu made changes - 02/Oct/06 01:43 PM
Status Resolved [ 5 ] Closed [ 6 ]