ldapsearch outputs LDAP results in a loop. The LDIF separator
after the result is printed. It's printed before the next result is printed.
This subtlety causes a problem for a program consuming the output of a
persistent ldapsearch (-Esync=rp).
Sorry, but anyone who wants to implement a robust syncrepl client should not
rely on ldapsearch command-line tool for that job. IMO it will never really
fit the requirements. Use a decent LDAP module for your programming language.