Home | History | Annotate | Download | only in overlays

Lines Matching refs:mapping

3 /* rwmmap.c - rewrite/mapping routines */
75 struct ldapmapping *mapping;
83 mapping = (struct ldapmapping *)ch_calloc( 2,
85 if ( mapping == NULL ) {
92 rc = slap_str2ad( "objectClass", &mapping[0].m_src_ad, &text );
94 ch_free( mapping );
98 mapping[0].m_dst_ad = mapping[0].m_src_ad;
99 ber_dupbv( &mapping[0].m_src, &mapping[0].m_src_ad->ad_cname );
100 ber_dupbv( &mapping[0].m_dst, &mapping[0].m_src );
102 mapping[1].m_src = mapping[0].m_src;
103 mapping[1].m_dst = mapping[0].m_dst;
104 mapping[1].m_src_ad = mapping[0].m_src_ad;
105 mapping[1].m_dst_ad = mapping[1].m_src_ad;
107 ldap_avl_insert( &lm->map, (caddr_t)&mapping[0],
109 ldap_avl_insert( &lm->remap, (caddr_t)&mapping[1],
112 *m = mapping;
159 struct ldapmapping *mapping;
161 /* map->map may be NULL when mapping is configured,
169 ( void )rwm_mapping( map, s, &mapping, remap );
170 if ( mapping != NULL ) {
171 if ( !BER_BVISNULL( &mapping->m_dst ) ) {
172 *bv = mapping->m_dst;
299 /* if no oc_map mapping was found and at_map required
394 struct ldapmapping *mapping;
396 if ( rwm_mapping( at_map, &an[i].an_name, &mapping, remap ) ) {
400 if ( !mapping ) {
403 } else if ( !BER_BVISNULL( &mapping->m_dst ) ) {
404 na[ j++ ] = mapping->m_dst.bv_val;
433 struct ldapmapping *mapping = NULL;
435 rwm_mapping( &dc->rwmap->rwm_at, &ad->ad_cname, &mapping, remap );
436 if ( mapping == NULL ) {
444 *mapped_attr = mapping->m_dst;
451 || ( mapping != NULL && mapping->m_dst_ad->ad_type->sat_syntax == slap_schema.si_syn_distinguishedName ) )
509 if ( mapping != NULL ) {
510 assert( mapping->m_dst_ad != NULL );
511 *adp = mapping->m_dst_ad;
1302 struct ldapmapping *mapping = v_mapping;
1304 if ( BER_BVISEMPTY( &mapping[0].m_dst ) ) {
1305 rwm_mapping_free( &mapping[ -1 ] );
1312 struct ldapmapping *mapping = v_mapping;
1314 if ( !BER_BVISNULL( &mapping[0].m_src ) ) {
1315 ch_free( mapping[0].m_src.bv_val );
1318 if ( mapping[0].m_flags & RWMMAP_F_FREE_SRC ) {
1319 if ( mapping[0].m_flags & RWMMAP_F_IS_OC ) {
1320 if ( mapping[0].m_src_oc ) {
1321 ch_free( mapping[0].m_src_oc );
1325 if ( mapping[0].m_src_ad ) {
1326 ch_free( mapping[0].m_src_ad );
1331 if ( !BER_BVISNULL( &mapping[0].m_dst ) ) {
1332 ch_free( mapping[0].m_dst.bv_val );
1335 if ( mapping[0].m_flags & RWMMAP_F_FREE_DST ) {
1336 if ( mapping[0].m_flags & RWMMAP_F_IS_OC ) {
1337 if ( mapping[0].m_dst_oc ) {
1338 ch_free( mapping[0].m_dst_oc );
1342 if ( mapping[0].m_dst_ad ) {
1343 ch_free( mapping[0].m_dst_ad );
1348 ch_free( mapping );