Changeset 740 for vendor/current/source4/winbind/wb_sids2xids.c
- Timestamp:
- Nov 14, 2012, 12:59:34 PM (12 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
TabularUnified vendor/current/source4/winbind/wb_sids2xids.c ¶
r414 r740 24 24 #include "winbind/wb_server.h" 25 25 #include "smbd/service_task.h" 26 #include "winbind/wb_helper.h"27 #include "libcli/security/proto.h"28 #include "winbind/idmap.h"29 26 30 27 struct sids2xids_state { 31 28 struct composite_context *ctx; 32 29 struct wbsrv_service *service; 33 struct id_map ping*ids;30 struct id_map *ids; 34 31 int count; 35 32 }; … … 37 34 struct composite_context *wb_sids2xids_send(TALLOC_CTX *mem_ctx, 38 35 struct wbsrv_service *service, 39 int count, struct id_mapping*ids)36 unsigned int count, struct id_map *ids) 40 37 { 41 38 struct composite_context *result; 42 39 struct sids2xids_state *state; 40 struct id_map **pointer_array; 41 unsigned int i; 43 42 44 43 DEBUG(5, ("wb_sids2xids_send called\n")); … … 56 55 state->ids = ids; 57 56 57 /* We need to convert between calling conventions here - the 58 * values are filled in by reference, so we just need to 59 * provide pointers to them */ 60 pointer_array = talloc_array(state, struct id_map *, count+1); 61 if (composite_nomem(pointer_array, result)) return result; 62 63 for (i=0; i < count; i++) { 64 pointer_array[i] = &ids[i]; 65 } 66 pointer_array[i] = NULL; 67 58 68 state->ctx->status = idmap_sids_to_xids(service->idmap_ctx, mem_ctx, 59 count, state->ids);69 pointer_array); 60 70 if (!composite_is_ok(state->ctx)) return result; 61 71 … … 65 75 66 76 NTSTATUS wb_sids2xids_recv(struct composite_context *ctx, 67 struct id_map ping**ids)77 struct id_map **ids) 68 78 { 69 79 NTSTATUS status = composite_wait(ctx); … … 73 83 DEBUG(5, ("wb_sids2xids_recv called\n")); 74 84 85 /* We don't have to mess with pointer_array on the way out, as 86 * the results are filled into the pointers the caller 87 * supplied */ 75 88 *ids = state->ids; 76 89
Note:
See TracChangeset
for help on using the changeset viewer.