Skip to content
Snippets Groups Projects
Commit c9242a12 authored by Kurt Zeilenga's avatar Kurt Zeilenga
Browse files

e_ndn = dn_normalize_case( e_dn )

parent 2805b256
No related branches found
No related tags found
No related merge requests found
......@@ -35,8 +35,8 @@ cache_entry_cmp( Entry *e1, Entry *e2 )
static int
cache_entrydn_cmp( Entry *e1, Entry *e2 )
{
/* compare their normalized dn's */
return( strcasecmp( e1->e_ndn, e2->e_ndn ) );
/* compare their normalized UPPERCASED dn's */
return( strcmp( e1->e_ndn, e2->e_ndn ) );
}
static int
......@@ -235,7 +235,7 @@ cache_find_entry_dn2id(
pthread_mutex_lock( &cache->c_mutex );
e.e_dn = dn;
e.e_ndn = dn_normalize( ch_strdup( dn ) );
e.e_ndn = dn_normalize_case( ch_strdup( dn ) );
if ( (ep = (Entry *) avl_find( cache->c_dntree, (caddr_t) &e,
cache_entrydn_cmp )) != NULL )
......
......@@ -136,7 +136,7 @@ pw2entry( Backend *be, struct passwd *pw )
sprintf( buf, "%s@%s", pw->pw_name, be->be_suffix[0] );
e->e_dn = ch_strdup( buf );
e->e_ndn = ch_strdup( buf );
e->e_ndn = dn_normalize_case( ch_strdup( buf ) );
val.bv_val = pw->pw_name;
val.bv_len = strlen( pw->pw_name );
......
......@@ -109,7 +109,7 @@ str2entry( char *s )
e->e_id, e->e_ndn, value );
free( e->e_ndn );
}
e->e_ndn = dn_normalize( ch_strdup( value ) );
e->e_ndn = dn_normalize_case( ch_strdup( value ) );
continue;
}
......
......@@ -49,7 +49,7 @@ monitor_info( Connection *conn, Operation *op )
entry_rdwr_init(e);
e->e_attrs = NULL;
e->e_dn = ch_strdup( SLAPD_MONITOR_DN );
e->e_ndn = NULL;
e->e_ndn = dn_normalize_case( ch_strdup(SLAPD_MONITOR_DN) );
val.bv_val = Versionstr;
if (( p = strchr( Versionstr, '\n' )) == NULL ) {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment