diff options
Diffstat (limited to 'winsup/cygwin/grp.cc')
-rw-r--r-- | winsup/cygwin/grp.cc | 26 |
1 files changed, 13 insertions, 13 deletions
diff --git a/winsup/cygwin/grp.cc b/winsup/cygwin/grp.cc index 93af7063e..fdb524c29 100644 --- a/winsup/cygwin/grp.cc +++ b/winsup/cygwin/grp.cc @@ -32,7 +32,7 @@ details. */ on the first call that needs information from it. */ static NO_COPY const char *etc_group = "/etc/group"; -static struct group *group_buf; /* group contents in memory */ +static struct __group16 *group_buf; /* group contents in memory */ static int curr_lines; static int max_lines; @@ -46,7 +46,7 @@ static int grp_pos = 0; static pwdgrp_check group_state; static int -parse_grp (struct group &grp, const char *line) +parse_grp (struct __group16 &grp, const char *line) { int len = strlen(line); char *newline = (char *) malloc (len + 1); @@ -111,7 +111,7 @@ add_grp_line (const char *line) if (curr_lines == max_lines) { max_lines += 10; - group_buf = (struct group *) realloc (group_buf, max_lines * sizeof (struct group)); + group_buf = (struct __group16 *) realloc (group_buf, max_lines * sizeof (struct __group16)); } if (parse_grp (group_buf[curr_lines], line)) curr_lines++; @@ -208,10 +208,10 @@ read_etc_group () } extern "C" -struct group * -getgrgid (gid_t gid) +struct __group16 * +getgrgid (__gid16_t gid) { - struct group * default_grp = NULL; + struct __group16 * default_grp = NULL; if (group_state <= initializing) read_etc_group(); @@ -227,7 +227,7 @@ getgrgid (gid_t gid) } extern "C" -struct group * +struct __group16 * getgrnam (const char *name) { if (group_state <= initializing) @@ -249,7 +249,7 @@ endgrent() } extern "C" -struct group * +struct __group16 * getgrent() { if (group_state <= initializing) @@ -269,7 +269,7 @@ setgrent () } /* Internal function. ONLY USE THIS INTERNALLY, NEVER `getgrent'!!! */ -struct group * +struct __group16 * internal_getgrent (int pos) { if (group_state <= initializing) @@ -281,12 +281,12 @@ internal_getgrent (int pos) } int -getgroups (int gidsetsize, gid_t *grouplist, gid_t gid, const char *username) +getgroups (int gidsetsize, __gid16_t *grouplist, __gid16_t gid, const char *username) { HANDLE hToken = NULL; DWORD size; int cnt = 0; - struct group *gr; + struct __group16 *gr; if (group_state <= initializing) read_etc_group(); @@ -356,14 +356,14 @@ error: extern "C" int -getgroups (int gidsetsize, gid_t *grouplist) +getgroups (int gidsetsize, __gid16_t *grouplist) { return getgroups (gidsetsize, grouplist, myself->gid, cygheap->user.name ()); } extern "C" int -initgroups (const char *, gid_t) +initgroups (const char *, __gid16_t) { return 0; } |