From b800bd4729fb703c52b2d8ff337dcd4d66ae9500 Mon Sep 17 00:00:00 2001 From: Howard Chu Date: Sat, 14 Nov 2009 21:25:11 +0000 Subject: [PATCH] ITS#6377, fix rev 1.478 --- servers/slapd/syncrepl.c | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) diff --git a/servers/slapd/syncrepl.c b/servers/slapd/syncrepl.c index dc765f9777..e098251824 100644 --- a/servers/slapd/syncrepl.c +++ b/servers/slapd/syncrepl.c @@ -165,13 +165,6 @@ init_syncrepl(syncinfo_t *si) sync_descs[3] = NULL; } - if ( SLAP_SYNC_SUBENTRY( si->si_be )) { - build_new_dn( &si->si_contextdn, &si->si_be->be_nsuffix[0], - (struct berval *)&slap_ldapsync_cn_bv, NULL ); - } else { - si->si_contextdn = si->si_be->be_nsuffix[0]; - } - if ( si->si_allattrs && si->si_allopattrs ) attrs = NULL; else @@ -1335,6 +1328,12 @@ do_syncrepl( } else { si->si_wbe = be; } + if ( SLAP_SYNC_SUBENTRY( si->si_wbe )) { + build_new_dn( &si->si_contextdn, &si->si_wbe->be_nsuffix[0], + (struct berval *)&slap_ldapsync_cn_bv, NULL ); + } else { + si->si_contextdn = si->si_wbe->be_nsuffix[0]; + } } if ( !si->si_schemachecking ) op->o_no_schema_check = 1; -- 2.39.5