Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Menu
Open sidebar
Joe Martin
OpenLDAP
Commits
6e70edbc
Commit
6e70edbc
authored
Mar 17, 2009
by
Quanah Gibson-Mount
Browse files
More for ITS#5988
parent
427d7661
Changes
1
Hide whitespace changes
Inline
Side-by-side
servers/slapd/overlays/syncprov.c
View file @
6e70edbc
...
...
@@ -1644,7 +1644,7 @@ syncprov_op_response( Operation *op, SlapReply *rs )
maxcsn
.
bv_len
=
sizeof
(
cbuf
);
ldap_pvt_thread_rdwr_wlock
(
&
si
->
si_csn_rwlock
);
if
(
op
->
o_dont_replicate
&&
if
(
op
->
o_dont_replicate
&&
op
->
o_tag
==
LDAP_REQ_MODIFY
&&
op
->
orm_modlist
->
sml_op
==
LDAP_MOD_REPLACE
&&
op
->
orm_modlist
->
sml_desc
==
slap_schema
.
si_ad_contextCSN
)
{
/* Catch contextCSN updates from syncrepl. We have to look at
...
...
@@ -1733,10 +1733,12 @@ syncprov_op_response( Operation *op, SlapReply *rs )
sizeof
(
int
));
si
->
si_sids
[
i
]
=
sid
;
}
#if 0
} else if ( !foundit ) {
/* internal ops that aren't meant to be replicated */
ldap_pvt_thread_rdwr_wunlock( &si->si_csn_rwlock );
return SLAP_CB_CONTINUE;
#endif
}
/* Don't do any processing for consumer contextCSN updates */
...
...
@@ -1747,17 +1749,23 @@ syncprov_op_response( Operation *op, SlapReply *rs )
si
->
si_numops
++
;
if
(
si
->
si_chkops
||
si
->
si_chktime
)
{
if
(
si
->
si_chkops
&&
si
->
si_numops
>=
si
->
si_chkops
)
{
do_check
=
1
;
si
->
si_numops
=
0
;
}
if
(
si
->
si_chktime
&&
(
op
->
o_time
-
si
->
si_chklast
>=
si
->
si_chktime
))
{
if
(
si
->
si_chklast
)
{
/* Never checkpoint adding the context entry,
* it will deadlock
*/
if
(
op
->
o_tag
!=
LDAP_REQ_ADD
||
!
dn_match
(
&
op
->
o_req_ndn
,
&
op
->
o_bd
->
be_nsuffix
[
0
]
))
{
if
(
si
->
si_chkops
&&
si
->
si_numops
>=
si
->
si_chkops
)
{
do_check
=
1
;
si
->
si_chklast
=
op
->
o_time
;
}
else
{
si
->
si_chklast
=
1
;
si
->
si_numops
=
0
;
}
if
(
si
->
si_chktime
&&
(
op
->
o_time
-
si
->
si_chklast
>=
si
->
si_chktime
))
{
if
(
si
->
si_chklast
)
{
do_check
=
1
;
si
->
si_chklast
=
op
->
o_time
;
}
else
{
si
->
si_chklast
=
1
;
}
}
}
}
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment