Author: jra Date: 2006-04-17 17:16:46 +0000 (Mon, 17 Apr 2006) New Revision: 15107
WebSVN: http://websvn.samba.org/cgi-bin/viewcvs.cgi?view=rev&root=samba&rev=15107 Log: 64 bit fixes. size_t on a 64-bit box is not uint32. Jeremy. Modified: branches/SAMBA_3_0/source/nsswitch/winbindd_group.c Changeset: Modified: branches/SAMBA_3_0/source/nsswitch/winbindd_group.c =================================================================== --- branches/SAMBA_3_0/source/nsswitch/winbindd_group.c 2006-04-17 17:16:35 UTC (rev 15106) +++ branches/SAMBA_3_0/source/nsswitch/winbindd_group.c 2006-04-17 17:16:46 UTC (rev 15107) @@ -208,6 +208,7 @@ fstring name_domain, name_group; char *tmp, *gr_mem; size_t gr_mem_len; + size_t num_gr_mem; gid_t gid; union unid_t id; NTSTATUS status; @@ -311,12 +312,14 @@ if (!fill_grent(&state->response.data.gr, name_domain, name_group, gid) || !fill_grent_mem(domain, &group_sid, name_type, - &state->response.data.gr.num_gr_mem, + &num_gr_mem, &gr_mem, &gr_mem_len)) { request_error(state); return; } + state->response.data.gr.num_gr_mem = (uint32)num_gr_mem; + /* Group membership lives at start of extra data */ state->response.data.gr.gr_mem_ofs = 0; @@ -336,6 +339,7 @@ fstring dom_name; fstring group_name; size_t gr_mem_len; + size_t num_gr_mem; char *gr_mem; NTSTATUS status; @@ -405,12 +409,14 @@ if (!fill_grent(&state->response.data.gr, dom_name, group_name, state->request.data.gid) || !fill_grent_mem(domain, &group_sid, name_type, - &state->response.data.gr.num_gr_mem, + &num_gr_mem, &gr_mem, &gr_mem_len)) { request_error(state); return; } + state->response.data.gr.num_gr_mem = (uint32)num_gr_mem; + /* Group membership lives at start of extra data */ state->response.data.gr.gr_mem_ofs = 0; @@ -756,6 +762,7 @@ /* Fill in group membership entry */ if (result) { + size_t num_gr_mem = 0; DOM_SID member_sid; group_list[group_list_ndx].num_gr_mem = 0; gr_mem = NULL; @@ -771,8 +778,10 @@ domain, &member_sid, SID_NAME_DOM_GRP, - &group_list[group_list_ndx].num_gr_mem, + &num_gr_mem, &gr_mem, &gr_mem_len); + + group_list[group_list_ndx].num_gr_mem = (uint32)num_gr_mem; } }