Lines Matching refs:state
66 struct sdap_search_bases_ex_state *state;
69 req = tevent_req_create(mem_ctx, &state, struct sdap_search_bases_ex_state);
80 state->ev = ev;
81 state->opts = opts;
82 state->sh = sh;
83 state->bases = bases;
84 state->map = map;
85 state->filter = filter;
86 state->attrs = attrs;
87 state->allow_paging = allow_paging;
88 state->return_first_reply = return_first_reply;
90 state->timeout = timeout == 0
94 if (state->map != NULL) {
95 for (state->map_num_attrs = 0;
96 state->map[state->map_num_attrs].opt_name != NULL;
97 state->map_num_attrs++) {
101 state->map_num_attrs = 0;
104 if (state->attrs == NULL && state->map != NULL) {
105 ret = build_attrs_from_map(state, state->map, state->map_num_attrs,
106 NULL, &state->attrs, NULL);
114 state->base_iter = 0;
134 struct sdap_search_bases_ex_state *state;
138 state = tevent_req_data(req, struct sdap_search_bases_ex_state);
139 state->cur_base = state->bases[state->base_iter];
140 if (state->cur_base == NULL) {
145 filter = sdap_combine_filters(state, state->filter,
146 state->cur_base->filter);
152 state->cur_base->basedn);
154 subreq = sdap_get_generic_send(state, state->ev, state->opts, state->sh,
155 state->cur_base->basedn,
156 state->cur_base->scope, filter,
157 state->attrs, state->map,
158 state->map_num_attrs, state->timeout,
159 state->allow_paging);
166 state->base_iter++;
173 struct sdap_search_bases_ex_state *state;
180 state = tevent_req_data(req, struct sdap_search_bases_ex_state);
183 state->cur_base->basedn);
185 ret = sdap_get_generic_recv(subreq, state, &count, &attrs);
194 if (state->return_first_reply == false) {
196 state->reply = talloc_realloc(state, state->reply,
198 state->reply_count + count);
199 if (state->reply == NULL) {
205 state->reply[state->reply_count + i] = talloc_steal(state->reply,
209 state->reply_count += count;
212 state->reply_count = count;
213 state->reply = attrs;
235 struct sdap_search_bases_ex_state *state =
240 *reply_count = state->reply_count;
241 *reply = talloc_steal(mem_ctx, state->reply);
335 struct sdap_deref_bases_ex_state *state;
338 req = tevent_req_create(mem_ctx, &state, struct sdap_deref_bases_ex_state);
355 state->ev = ev;
356 state->opts = opts;
357 state->sh = sh;
358 state->bases = bases;
359 state->maps = maps;
360 state->filter = filter;
361 state->attrs = attrs;
362 state->deref_attr = deref_attr;
363 state->return_first_reply = return_first_reply;
364 state->flags = flags;
366 state->timeout = timeout == 0
370 for (state->num_maps = 0; maps[state->num_maps].map != NULL;
371 state->num_maps++) {
375 state->base_iter = 0;
395 struct sdap_deref_bases_ex_state *state;
398 state = tevent_req_data(req, struct sdap_deref_bases_ex_state);
399 state->cur_base = state->bases[state->base_iter];
400 if (state->cur_base == NULL) {
405 state->cur_base->basedn);
407 subreq = sdap_deref_search_with_filter_send(state, state->ev, state->opts,
408 state->sh, state->cur_base->basedn, state->filter,
409 state->deref_attr, state->attrs, state->num_maps, state->maps,
410 state->timeout, state->flags);
417 state->base_iter++;
424 struct sdap_deref_bases_ex_state *state;
431 state = tevent_req_data(req, struct sdap_deref_bases_ex_state);
434 state->cur_base->basedn);
436 ret = sdap_deref_search_with_filter_recv(subreq, state, &count, &attrs);
445 if (state->return_first_reply == false) {
447 state->reply = talloc_realloc(state, state->reply,
449 state->reply_count + count);
450 if (state->reply == NULL) {
456 state->reply[state->reply_count + i] = talloc_steal(state->reply,
460 state->reply_count += count;
463 state->reply_count = count;
464 state->reply = attrs;
486 struct sdap_deref_bases_ex_state *state =
491 *reply_count = state->reply_count;
492 *reply = talloc_steal(mem_ctx, state->reply);