const char *name
)
{
- struct aindexrec *air;
- char *tmpname;
-
- {
- tmpname = (char *)name;
- }
+ struct aindexrec *air;
- if ( (air = (struct aindexrec *) avl_find( attr_index, tmpname,
- (AVL_CMP) attr_index_name_cmp )) != NULL ) {
- if ( tmpname != name )
- ldap_memfree( tmpname );
- return( air->air_at );
- }
+ air = (struct aindexrec *) avl_find( attr_index, name,
+ (AVL_CMP) attr_index_name_cmp );
- if ( tmpname != name )
- ldap_memfree( tmpname );
- return( NULL );
+ return air != NULL ? air->air_at : NULL;
}
int