[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Bug-gnulib] getgroups.c merge from coreutils
From: |
Paul Eggert |
Subject: |
[Bug-gnulib] getgroups.c merge from coreutils |
Date: |
04 Aug 2003 22:32:40 -0700 |
User-agent: |
Gnus/5.09 (Gnus v5.9.0) Emacs/21.3 |
I installed this patch from coreutils:
2003-08-04 Paul Eggert <address@hidden>
Merge from coreutils.
* getgroups.c: Include "xalloc.h" instead of declaring xalloc fns;
from Dmitry V. Levin.
Remove anachronistic cast of xrealloc.
Index: getgroups.c
===================================================================
RCS file: /cvsroot/gnulib/gnulib/lib/getgroups.c,v
retrieving revision 1.6
retrieving revision 1.7
diff -p -u -r1.6 -r1.7
--- getgroups.c 7 Aug 2000 15:48:18 -0000 1.6
+++ getgroups.c 5 Aug 2003 05:29:41 -0000 1.7
@@ -1,5 +1,5 @@
/* provide consistent interface to getgroups for systems that don't allow N==0
- Copyright (C) 1996, 1999 Free Software Foundation, Inc.
+ Copyright (C) 1996, 1999, 2003 Free Software Foundation, Inc.
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
@@ -21,7 +21,7 @@
#include <stdio.h>
#include <sys/types.h>
-char *xmalloc ();
+#include "xalloc.h"
/* On at least Ultrix 4.3 and NextStep 3.2, getgroups (0, 0) always fails.
On other systems, it returns the number of supplemental groups for the
@@ -43,7 +43,7 @@ getgroups (size_t n, GETGROUPS_T *group)
gbuf = NULL;
while (1)
{
- gbuf = (GETGROUPS_T *) xrealloc (gbuf, n * sizeof (GETGROUPS_T));
+ gbuf = xrealloc (gbuf, n * sizeof (GETGROUPS_T));
n_groups = getgroups (n, gbuf);
if (n_groups < n)
break;
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Bug-gnulib] getgroups.c merge from coreutils,
Paul Eggert <=