mirror of
https://git.openldap.org/openldap/openldap.git
synced 2026-01-02 21:19:53 -05:00
don't muck with shadow flags if database is already shadow (ITS#5850)
This commit is contained in:
parent
bd49d6dc11
commit
d8e4b48cee
1 changed files with 10 additions and 1 deletions
|
|
@ -3069,7 +3069,16 @@ config_shadow( ConfigArgs *c, int flag )
|
|||
return 1;
|
||||
}
|
||||
|
||||
SLAP_DBFLAGS(c->be) |= (SLAP_DBFLAG_SHADOW | SLAP_DBFLAG_SINGLE_SHADOW | flag);
|
||||
if ( SLAP_SHADOW(c->be) ) {
|
||||
/* if already shadow, only check consistency */
|
||||
if ( ( SLAP_DBFLAGS(c->be) & flag ) != flag ) {
|
||||
Debug( LDAP_DEBUG_ANY, "%s: inconsistent shadow flag 0x%x.\n", c->log, flag, 0 );
|
||||
return 1;
|
||||
}
|
||||
|
||||
} else {
|
||||
SLAP_DBFLAGS(c->be) |= (SLAP_DBFLAG_SHADOW | SLAP_DBFLAG_SINGLE_SHADOW | flag);
|
||||
}
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue