mirror of
https://git.openldap.org/openldap/openldap.git
synced 2025-01-06 10:46:21 +08:00
Fix ITS#3717 - set restriction on all backends
Fix ITS#4217 - gentleHUP is a normal shutdown condition
This commit is contained in:
parent
d84ffb62a6
commit
80143b5fc6
@ -1729,9 +1729,13 @@ slapd_daemon_task(
|
||||
ber_socket_t active;
|
||||
|
||||
if( slapd_gentle_shutdown == 1 ) {
|
||||
BackendDB *be;
|
||||
Debug( LDAP_DEBUG_ANY, "slapd gentle shutdown\n", 0, 0, 0 );
|
||||
close_listeners( 1 );
|
||||
frontendDB->be_restrictops |= SLAP_RESTRICT_OP_WRITES;
|
||||
LDAP_STAILQ_FOREACH(be, &backendDB, be_next) {
|
||||
be->be_restrictops |= SLAP_RESTRICT_OP_WRITES;
|
||||
}
|
||||
slapd_gentle_shutdown = 2;
|
||||
}
|
||||
|
||||
@ -1739,7 +1743,7 @@ slapd_daemon_task(
|
||||
active = slap_daemon.sd_nactives;
|
||||
ldap_pvt_thread_mutex_unlock( &slap_daemon.sd_mutex );
|
||||
if( active == 0 ) {
|
||||
slapd_shutdown = 2;
|
||||
slapd_shutdown = 1;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user