% ./configure --help
- to list available configuration options. A description of these
- options is provided in the 'CONFIGURE OPTIONS' section below.
+ to list available configuration options.
The configure script uses environmental variables for determining
compiler/linker options including:
int ( *sv2s ) ( struct berval *v, char *s, unsigned f, ber_len_t *l );
assert( bv );
-
bv->bv_len = 0;
bv->bv_val = NULL;
case LDAP_DN_FORMAT_LDAPV3:
sv2l = strval2strlen;
sv2s = strval2str;
- goto got_funcs;
+ if( 0 ) {
case LDAP_DN_FORMAT_LDAPV2:
- sv2l = strval2IA5strlen;
- sv2s = strval2IA5str;
-got_funcs:
-
+ sv2l = strval2IA5strlen;
+ sv2s = strval2IA5str;
+ }
+
for ( iRDN = 0, len = 0; dn[ 0 ][ iRDN ]; iRDN++ ) {
ber_len_t rdnl;
LDAPRDN *rdn = dn[ 0 ][ iRDN ];
break;
case LDAP_DN_FORMAT_UFN: {
-
/*
* FIXME: quoting from RFC 1781:
*
#endif /* DC_IN_UFN */
rc = LDAP_SUCCESS;
- break;
- }
- case LDAP_DN_FORMAT_DCE:
+ } break;
+ case LDAP_DN_FORMAT_DCE:
for ( iRDN = 0, len = 0; dn[ 0 ][ iRDN ]; iRDN++ ) {
ber_len_t rdnl;
LDAPRDN *rdn = dn[ 0 ][ iRDN ];
break;
case LDAP_DN_FORMAT_AD_CANONICAL: {
-
/*
* Sort of UFN for DCE DNs: a slash ('/') separated
* global->local DN with no types; strictly speaking,
bv->bv_val[ bv->bv_len ] = '\0';
rc = LDAP_SUCCESS;
- break;
- }
+ } break;
default:
return LDAP_PARAM_ERROR;
Debug( LDAP_DEBUG_TRACE, "<= ldap_dn2bv(%s,%u)=%d\n",
bv->bv_val, flags, rc );
+
return_results:;
return( rc );
}
*/
ava->la_attr = ad->ad_cname;
- if( flags & SLAP_LDAPDN_PRETTY ) {
+ if( ava->la_flags & LDAP_AVA_BINARY ) {
+ /* AVA is binary encoded, don't muck with it */
+ transf = NULL;
+ mr = NULL;
+
+ } else if( flags & SLAP_LDAPDN_PRETTY ) {
transf = ad->ad_type->sat_syntax->ssyn_pretty;
mr = NULL;
} else {
if ( transf ) {
/*
* transform value by normalize/pretty function
+ * if value is empty, use empty_bv
*/
rc = ( *transf )( ad->ad_type->sat_syntax,
- &ava->la_value, &bv );
+ ava->la_value.bv_len
+ ? &ava->la_value
+ : (struct berval *) &slap_empty_bv,
+ &bv );
if ( rc != LDAP_SUCCESS ) {
return LDAP_INVALID_SYNTAX;