- Debug( LDAP_DEBUG_ANY, "out of memory\n", 0,0,0 );
+ Debug( LDAP_DEBUG_ANY, "out of memory\n", 0, 0, 0 );
+ }
+
+ i = 0;
+ if ( si->si_allattrs ) {
+ attrs[i++] = ch_strdup( "*" );
+ }
+
+ if ( si->si_allopattrs ) {
+ attrs[i++] = ch_strdup( "+" );
+ } else {
+ for ( j = 0; sync_descs[ j ] != NULL; j++ ) {
+ attrs[ i++ ] = ch_strdup ( sync_descs[j]->ad_cname.bv_val );
+ }
+ }
+ attrs[i] = NULL;
+
+ if ( !si->si_allattrs && !si->si_allopattrs ) {
+ attrs[0] = ch_strdup( "*" );
+ attrs[1] = ch_strdup( "+" );
+ attrs[2] = NULL;