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
openldap
OpenLDAP
Commits
48695235
Commit
48695235
authored
Nov 30, 2004
by
Howard Chu
Browse files
Add comments, fix search args in syncrepl_entry
parent
0c65f51a
Changes
1
Hide whitespace changes
Inline
Side-by-side
servers/slapd/syncrepl.c
View file @
48695235
...
@@ -1279,7 +1279,7 @@ syncrepl_entry(
...
@@ -1279,7 +1279,7 @@ syncrepl_entry(
op
->
o_tag
=
LDAP_REQ_SEARCH
;
op
->
o_tag
=
LDAP_REQ_SEARCH
;
op
->
ors_scope
=
LDAP_SCOPE_SUBTREE
;
op
->
ors_scope
=
LDAP_SCOPE_SUBTREE
;
/* get
syncrepl cookie of shadow replica from subentry
*/
/* get
the entry for this UUID
*/
op
->
o_req_dn
=
si
->
si_base
;
op
->
o_req_dn
=
si
->
si_base
;
op
->
o_req_ndn
=
si
->
si_base
;
op
->
o_req_ndn
=
si
->
si_base
;
...
@@ -1287,8 +1287,8 @@ syncrepl_entry(
...
@@ -1287,8 +1287,8 @@ syncrepl_entry(
op
->
ors_tlimit
=
SLAP_NO_LIMIT
;
op
->
ors_tlimit
=
SLAP_NO_LIMIT
;
op
->
ors_slimit
=
1
;
op
->
ors_slimit
=
1
;
op
->
ors_attrs
=
slap_anlist_
no
_attrs
;
op
->
ors_attrs
=
slap_anlist_
all
_attr
ibute
s
;
op
->
ors_attrsonly
=
1
;
op
->
ors_attrsonly
=
0
;
/* set callback function */
/* set callback function */
op
->
o_callback
=
&
cb
;
op
->
o_callback
=
&
cb
;
...
@@ -2111,7 +2111,12 @@ dn_callback(
...
@@ -2111,7 +2111,12 @@ dn_callback(
Attribute
*
old
,
*
new
;
Attribute
*
old
,
*
new
;
int
i
;
int
i
;
/* Did the DN change? */
/* Did the DN change? Note that we don't explicitly try to
* discover if the deleteOldRdn argument applies here. It
* would save an unnecessary Modify if we detected it, but
* that's a fair amount of trouble to compare the two attr
* lists in detail.
*/
if
(
!
dn_match
(
&
rs
->
sr_entry
->
e_name
,
if
(
!
dn_match
(
&
rs
->
sr_entry
->
e_name
,
&
dni
->
new_entry
->
e_name
)
)
&
dni
->
new_entry
->
e_name
)
)
{
{
...
@@ -2125,6 +2130,12 @@ dn_callback(
...
@@ -2125,6 +2130,12 @@ dn_callback(
dni
->
attrs
=
i
;
dni
->
attrs
=
i
;
/* We assume that attributes are saved in the same order
* in the remote and local databases. So if we walk through
* the attributeDescriptions one by one they should match in
* lock step. If not, we signal a change. Otherwise we test
* all the values...
*/
for
(
old
=
rs
->
sr_entry
->
e_attrs
,
new
=
dni
->
new_entry
->
e_attrs
;
for
(
old
=
rs
->
sr_entry
->
e_attrs
,
new
=
dni
->
new_entry
->
e_attrs
;
old
&&
new
;
old
&&
new
;
old
=
old
->
a_next
,
new
=
new
->
a_next
)
old
=
old
->
a_next
,
new
=
new
->
a_next
)
...
...
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