- ber_str2bv( replace, 0, 0, &bv );
- rc = slap_parseURI( &bv, ®->sr_replace.dn, ®->sr_replace.scope,
- &filter, ®->sr_replace.filter );
- if ( filter ) filter_free( filter );
- if ( rc ) {
-#ifdef NEW_LOGGING
- LDAP_LOG(( "sasl", LDAP_LEVEL_ERR,
- "slap_sasl_regexp_config: \"%s\" could not be parsed.\n",
- replace ));
-#else
- Debug( LDAP_DEBUG_ANY,
- "SASL replace pattern %s could not be parsed.\n",
- replace, 0, 0 );
-#endif
- return( rc );
- }
+ reg = &SaslRegexp[nSaslRegexp];
+
+ reg->sr_match = ch_strdup( match );
+ reg->sr_replace = ch_strdup( replace );