mirror of
https://git.openldap.org/openldap/openldap.git
synced 2025-01-06 10:46:21 +08:00
config cleanup handler
This commit is contained in:
parent
5bf5288be5
commit
88cdbab5f4
@ -3897,6 +3897,8 @@ config_modify_internal( CfEntryInfo *ce, Operation *op, SlapReply *rs,
|
||||
}
|
||||
|
||||
out:
|
||||
if ( ca.cleanup )
|
||||
ca.cleanup( &ca );
|
||||
if ( rc == LDAP_SUCCESS ) {
|
||||
attrs_free( save_attrs );
|
||||
} else {
|
||||
|
@ -81,6 +81,10 @@ typedef struct ConfigOCs {
|
||||
#endif
|
||||
} ConfigOCs;
|
||||
|
||||
struct config_args_s;
|
||||
|
||||
typedef int (ConfigDriver)(struct config_args_s *c);
|
||||
|
||||
typedef struct config_args_s {
|
||||
int argc;
|
||||
char **argv;
|
||||
@ -114,6 +118,7 @@ typedef struct config_args_s {
|
||||
BackendDB *be;
|
||||
BackendInfo *bi;
|
||||
void *private; /* anything */
|
||||
ConfigDriver *cleanup;
|
||||
} ConfigArgs;
|
||||
|
||||
#define value_int values.v_int
|
||||
@ -124,8 +129,6 @@ typedef struct config_args_s {
|
||||
#define value_dn values.v_dn.vdn_dn
|
||||
#define value_ndn values.v_dn.vdn_ndn
|
||||
|
||||
typedef int (ConfigDriver)(ConfigArgs *c);
|
||||
|
||||
int config_register_schema(ConfigTable *ct, ConfigOCs *co);
|
||||
int config_get_vals(ConfigTable *ct, ConfigArgs *c);
|
||||
int config_add_vals(ConfigTable *ct, ConfigArgs *c);
|
||||
|
Loading…
Reference in New Issue
Block a user