From c419a3e4f76af2c82a149580066cf0287b7e5e45 Mon Sep 17 00:00:00 2001 From: Howard Chu Date: Sun, 15 Nov 2009 19:15:12 +0000 Subject: [PATCH] ITS#6367 use correct SID in our request cookie --- servers/slapd/syncrepl.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/servers/slapd/syncrepl.c b/servers/slapd/syncrepl.c index 4933933935..9b6d4d3c00 100644 --- a/servers/slapd/syncrepl.c +++ b/servers/slapd/syncrepl.c @@ -665,6 +665,11 @@ do_syncrep1( si->si_syncCookie.ctxcsn, si->si_syncCookie.rid, si->si_syncCookie.sid ); } else { + /* ITS#6367: recreate the cookie so it has our SID, not our peer's */ + ch_free( si->si_syncCookie.octet_str.bv_val ); + slap_compose_sync_cookie( NULL, &si->si_syncCookie.octet_str, + si->si_syncCookie.ctxcsn, si->si_syncCookie.rid, + si->si_syncCookie.sid ); /* Look for contextCSN from syncprov overlay. */ check_syncprov( op, si ); } -- 2.39.5