From: Kurt Zeilenga Date: Sat, 14 Jul 2001 01:26:02 +0000 (+0000) Subject: Quick and dirty hack to add password modify replication. X-Git-Tag: LDBM_PRE_GIANT_RWLOCK~1238 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=ca43453b95c60fd24a3b7907a5bec447e2a88804;p=openldap Quick and dirty hack to add password modify replication. --- diff --git a/servers/slapd/back-ldbm/passwd.c b/servers/slapd/back-ldbm/passwd.c index 9165831bad..c4f81e7c80 100644 --- a/servers/slapd/back-ldbm/passwd.c +++ b/servers/slapd/back-ldbm/passwd.c @@ -149,12 +149,14 @@ ldbm_back_exop_passwd( *text = "entry modify failed"; goto done; } - } - /* change the entry itself */ - if( id2entry_add( be, e ) != 0 ) { - *text = "entry update failed"; - rc = LDAP_OTHER; + /* change the entry itself */ + if( id2entry_add( be, e ) != 0 ) { + *text = "entry update failed"; + rc = LDAP_OTHER; + } + + replog( be, op, e->e_dn, &ml ); } done: diff --git a/servers/slapd/repl.c b/servers/slapd/repl.c index 443fe81d93..dc85c33a57 100644 --- a/servers/slapd/repl.c +++ b/servers/slapd/repl.c @@ -54,6 +54,11 @@ replog( fprintf( fp, "dn: %s\n", dn ); switch ( op->o_tag ) { + case LDAP_REQ_EXTENDED: + /* quick hack for extended operations */ + /* assume change parameter is a Modfications* */ + /* fall thru */ + case LDAP_REQ_MODIFY: fprintf( fp, "changetype: modify\n" ); ml = change; diff --git a/servers/slapd/tools/mimic.c b/servers/slapd/tools/mimic.c index b5d67cf970..55ea31cb56 100644 --- a/servers/slapd/tools/mimic.c +++ b/servers/slapd/tools/mimic.c @@ -163,3 +163,8 @@ void connection2anonymous( Connection *c ) assert(0); } +void replog( Backend *be, Operation *op, char *dn, void *change) +{ + assert(0); +} +