diff options
author | Noriko Hosoi <nhosoi@redhat.com> | 2010-01-22 09:47:52 -0800 |
---|---|---|
committer | Noriko Hosoi <nhosoi@jiji.localdomain> | 2010-01-22 10:36:16 -0800 |
commit | b5e653a844af60596f9bc6b16349ee902ddb51f5 (patch) | |
tree | d22f47113e303de236e9a9b01376cb6e3d14486f /ldap/servers/plugins/replication/windows_connection.c | |
parent | 4d93699a71acb061c5787d2b8b61a0417ce02808 (diff) | |
download | ds-b5e653a844af60596f9bc6b16349ee902ddb51f5.tar.gz ds-b5e653a844af60596f9bc6b16349ee902ddb51f5.tar.xz ds-b5e653a844af60596f9bc6b16349ee902ddb51f5.zip |
Allow modrdn to move subtree and rename non-leaf node
This patch includes
- replacing the entrydn index with the entryrdn index
- replacing a full DN in each entry in the DB with an RDN
- extending Slapi_Entry, entry2str, and str2entry to absorb the changes
made on the entry
- adding DN/RDN helper functions
- adding DN cache
- adding a utility and a migration script to convert the DN format database
to the RDN format
- extending a database dump utility dbscan to support the entryrdn
- slapi_dn_syntax_check by nkinder@redhat.com is added to check the dn before
modify operations
- big fix for 171338 - Enhancement: winsync modrdn not synced
In addition to the above, compile warnings and memory leaks found in testing
the new feature are fixed.
For more details, see the feature design document at:
http://directory.fedoraproject.org/wiki/Subtree_Rename
and bugzilla at:
https://bugzilla.redhat.com/show_bug.cgi?id=171338
Diffstat (limited to 'ldap/servers/plugins/replication/windows_connection.c')
-rw-r--r-- | ldap/servers/plugins/replication/windows_connection.c | 13 |
1 files changed, 11 insertions, 2 deletions
diff --git a/ldap/servers/plugins/replication/windows_connection.c b/ldap/servers/plugins/replication/windows_connection.c index 8f7233ae..d0eadee1 100644 --- a/ldap/servers/plugins/replication/windows_connection.c +++ b/ldap/servers/plugins/replication/windows_connection.c @@ -276,6 +276,15 @@ windows_conn_get_error(Repl_Connection *conn, int *operation, int *error) LDAPDebug( LDAP_DEBUG_TRACE, "<= windows_conn_get_error\n", 0, 0, 0 ); } +void +windows_conn_set_error(Repl_Connection *conn, int error) +{ + LDAPDebug( LDAP_DEBUG_TRACE, "=> windows_conn_set_error\n", 0, 0, 0 ); + PR_Lock(conn->lock); + conn->last_ldap_error = error; + PR_Unlock(conn->lock); + LDAPDebug( LDAP_DEBUG_TRACE, "<= windows_conn_set_error\n", 0, 0, 0 ); +} /* * Common code to send an LDAPv3 operation and collect the result. @@ -297,7 +306,7 @@ windows_perform_operation(Repl_Connection *conn, int optype, const char *dn, const char *extop_oid, struct berval *extop_payload, char **retoidp, struct berval **retdatap, LDAPControl ***returned_controls) { - int rc; + int rc = LDAP_SUCCESS; ConnResult return_value; LDAPControl **loc_returned_controls; const char *op_string = NULL; @@ -658,7 +667,7 @@ windows_search_entry_ext(Repl_Connection *conn, char* searchbase, char *filter, nummessages = ldap_count_messages(conn->ld, res); numentries = ldap_count_entries(conn->ld, res); numreferences = ldap_count_references(conn->ld, res); - LDAPDebug( LDAP_DEBUG_REPL, "windows_search_entry: recieved %d messages, %d entries, %d references\n", + LDAPDebug( LDAP_DEBUG_REPL, "windows_search_entry: received %d messages, %d entries, %d references\n", nummessages, numentries, numreferences ); } |