ITS#9015 Treat an empty cookie from a FALLBACK search as a success

This commit is contained in:
Ondřej Kuzník 2019-05-07 16:42:51 +01:00
parent abcf0e8f23
commit 7ca538ff87

View File

@ -553,7 +553,8 @@ ldap_sync_search(
}
} else
#endif
if ( si->si_logstate == SYNCLOG_LOGGING && !si->si_syncCookie.numcsns ) {
if ( si->si_logstate == SYNCLOG_LOGGING && !si->si_syncCookie.numcsns &&
!si->si_refreshDone ) {
si->si_logstate = SYNCLOG_FALLBACK;
}
}
@ -1492,6 +1493,7 @@ logerr:
if ( err == LDAP_SUCCESS
&& si->si_logstate == SYNCLOG_FALLBACK ) {
si->si_logstate = SYNCLOG_LOGGING;
si->si_refreshDone = 1;
rc = LDAP_SYNC_REFRESH_REQUIRED;
slap_resume_listeners();
} else {