bug-coreutils
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH] Use getgrouplist where available.


From: James Youngman
Subject: Re: [PATCH] Use getgrouplist where available.
Date: Fri, 22 Feb 2008 09:23:32 +0000

On Fri, Feb 22, 2008 at 9:04 AM, Jim Meyering <address@hidden> wrote:

>  +      while (1)
>  +       {
>  +         GETGROUPS_T *h;
>  +         ng = getgrouplist (username, gid, g, &max_n_groups);
>  +         if (0 <= ng)
>  +           {
>  +             *groups = g;
>  +             return ng;
>  +           }
>  +
>  +         /* When getgrouplist fails, it guarantees that
>  +            max_n_groups reflects the new number of groups.  */
>  +
>  +         h = realloc (g, max_n_groups * sizeof *h);

Shouldn't realloc here be xnrealloc?

James.




reply via email to

[Prev in Thread] Current Thread [Next in Thread]