getgrouplist.c (6536) | getgrouplist.c (11659) |
---|---|
1/* 2 * Copyright (c) 1991, 1993 3 * The Regents of the University of California. All rights reserved. 4 * 5 * Redistribution and use in source and binary forms, with or without 6 * modification, are permitted provided that the following conditions 7 * are met: 8 * 1. Redistributions of source code must retain the above copyright --- 36 unchanged lines hidden (view full) --- 45int 46getgrouplist(uname, agroup, groups, grpcnt) 47 const char *uname; 48 int agroup; 49 register int *groups; 50 int *grpcnt; 51{ 52 register struct group *grp; | 1/* 2 * Copyright (c) 1991, 1993 3 * The Regents of the University of California. All rights reserved. 4 * 5 * Redistribution and use in source and binary forms, with or without 6 * modification, are permitted provided that the following conditions 7 * are met: 8 * 1. Redistributions of source code must retain the above copyright --- 36 unchanged lines hidden (view full) --- 45int 46getgrouplist(uname, agroup, groups, grpcnt) 47 const char *uname; 48 int agroup; 49 register int *groups; 50 int *grpcnt; 51{ 52 register struct group *grp; |
53 register struct passwd *pw; | |
54 register int i, ngroups; 55 int ret, maxgroups; 56 57 ret = 0; 58 ngroups = 0; 59 maxgroups = *grpcnt; 60 /* 61 * When installing primary group, duplicate it; --- 31 unchanged lines hidden --- | 53 register int i, ngroups; 54 int ret, maxgroups; 55 56 ret = 0; 57 ngroups = 0; 58 maxgroups = *grpcnt; 59 /* 60 * When installing primary group, duplicate it; --- 31 unchanged lines hidden --- |