ITS#5408 part 1 - error handling, debug output, add error texts (rs->sr_text).
- Reset rs->sr_text on success in apply_modify_to_entry(), not in its callers.
- Fix error test from ldif_write_entry() in ldif_move_entry().
- Start changing LDAP_UNWILLING_TO_PERFORM -> LDAP_OTHER for internal errors.
- Pass around LDAP result codes instead of errno.
- Rename spew_entry() -> ldif_write_entry(), move entry2str_mutex lock into it.
- Some other preparation for upcoming changes.