mirror of
https://git.openldap.org/openldap/openldap.git
synced 2026-01-07 15:41:24 -05:00
ITS#4813 don't limit the presence list to the current snapshot. add
some debug msgs for the sessionlog list.
This commit is contained in:
parent
52a7af8230
commit
1ce42136fb
1 changed files with 18 additions and 12 deletions
|
|
@ -580,7 +580,7 @@ syncprov_findcsn( Operation *op, find_csn_t mode )
|
|||
char buf[LDAP_LUTIL_CSNSTR_BUFSIZE + STRLENOF("(entryCSN<=)")];
|
||||
char cbuf[LDAP_LUTIL_CSNSTR_BUFSIZE];
|
||||
struct berval maxcsn;
|
||||
Filter cf, af;
|
||||
Filter cf;
|
||||
#ifdef LDAP_COMP_MATCH
|
||||
AttributeAssertion eq = { NULL, BER_BVNULL, NULL };
|
||||
#else
|
||||
|
|
@ -652,14 +652,8 @@ again:
|
|||
cb.sc_response = findcsn_cb;
|
||||
break;
|
||||
case FIND_PRESENT:
|
||||
af.f_choice = LDAP_FILTER_AND;
|
||||
af.f_next = NULL;
|
||||
af.f_and = &cf;
|
||||
cf.f_choice = LDAP_FILTER_LE;
|
||||
cf.f_av_value = srs->sr_state.ctxcsn;
|
||||
cf.f_next = op->ors_filter;
|
||||
fop.ors_filter = ⁡
|
||||
filter2bv_x( &fop, fop.ors_filter, &fop.ors_filterstr );
|
||||
fop.ors_filter = op->ors_filter;
|
||||
fop.ors_filterstr = op->ors_filterstr;
|
||||
fop.ors_attrsonly = 0;
|
||||
fop.ors_attrs = uuid_anlist;
|
||||
fop.ors_slimit = SLAP_NO_LIMIT;
|
||||
|
|
@ -703,7 +697,6 @@ again:
|
|||
break;
|
||||
case FIND_PRESENT:
|
||||
op->o_tmpfree( pcookie.uuids, op->o_tmpmemctx );
|
||||
op->o_tmpfree( fop.ors_filterstr.bv_val, op->o_tmpmemctx );
|
||||
break;
|
||||
}
|
||||
|
||||
|
|
@ -1388,9 +1381,22 @@ syncprov_playlog( Operation *op, SlapReply *rs, sessionlog *sl,
|
|||
* and everything else at the end. Do this first so we can
|
||||
* unlock the list mutex.
|
||||
*/
|
||||
Debug( LDAP_DEBUG_SYNC, "srs csn %s\n", srs-> sr_state.ctxcsn.bv_val, 0, 0 );
|
||||
for ( se=sl->sl_head; se; se=se->se_next ) {
|
||||
if ( ber_bvcmp( &se->se_csn, &srs->sr_state.ctxcsn ) <= 0 ) continue;
|
||||
if ( ber_bvcmp( &se->se_csn, ctxcsn ) > 0 ) break;
|
||||
Debug( LDAP_DEBUG_SYNC, "log csn %s\n", se-> se_csn.bv_val,
|
||||
0, 0 );
|
||||
ndel = ber_bvcmp( &se->se_csn, &srs->sr_state.ctxcsn );
|
||||
if ( ndel <= 0 ) {
|
||||
Debug( LDAP_DEBUG_SYNC, "cmp %d, too old\n", ndel,
|
||||
0, 0 );
|
||||
continue;
|
||||
}
|
||||
ndel = ber_bvcmp( &se->se_csn, ctxcsn );
|
||||
if ( ndel > 0 ) {
|
||||
Debug( LDAP_DEBUG_SYNC, "cmp %d, too new\n", ndel,
|
||||
0, 0 );
|
||||
break;
|
||||
}
|
||||
if ( se->se_tag == LDAP_REQ_DELETE ) {
|
||||
j = i;
|
||||
i++;
|
||||
|
|
|
|||
Loading…
Reference in a new issue