/* rewrite */
RWM_CF_REWRITE = 1,
RWM_CF_SUFFIXMASSAGE,
- RWM_CF_T_F_SUPPORT,
/* map */
RWM_CF_MAP,
+ RWM_CF_T_F_SUPPORT,
RWM_CF_NORMALIZE_MAPPED,
RWM_CF_LAST
switch ( c->type ) {
case RWM_CF_REWRITE:
- slap_rewrite_unparse( rwmap->rwm_bva_rewrite, &c->rvalue_vals );
- if ( !c->rvalue_vals ) rc = 1;
+ if ( rwmap->rwm_bva_rewrite == NULL ) {
+ rc = 1;
+
+ } else {
+ slap_rewrite_unparse( rwmap->rwm_bva_rewrite, &c->rvalue_vals );
+ if ( !c->rvalue_vals ) {
+ rc = 1;
+ }
+ }
break;
case RWM_CF_T_F_SUPPORT:
/* single modification is not allowed */
rc = 1;
- } else {
+ } else if ( rwmap->rwm_rw != NULL ) {
rewrite_info_delete( &rwmap->rwm_rw );
+ assert( rwmap->rwm_rw == NULL );
ber_bvarray_free( rwmap->rwm_bva_rewrite );
rwmap->rwm_bva_rewrite = NULL;
return rc;
}
-
-
-
-
-
-
static int
rwm_db_init(
BackendDB *be,