]> granicus.if.org Git - postgresql/commitdiff
Add gp->gr_mem != NULL check for Solaris, per Seth Hettich
authorBruce Momjian <bruce@momjian.us>
Mon, 29 Oct 2001 18:06:54 +0000 (18:06 +0000)
committerBruce Momjian <bruce@momjian.us>
Mon, 29 Oct 2001 18:06:54 +0000 (18:06 +0000)
src/backend/utils/init/findbe.c

index 675046e6aa421159466ce18d5342cc6350e0b8aa..1e44f2e45cb5492ed47013d99f7ed69fd8dabdaf 100644 (file)
@@ -7,7 +7,7 @@
  *
  *
  * IDENTIFICATION
- *       $Header: /cvsroot/pgsql/src/backend/utils/init/Attic/findbe.c,v 1.24 2001/10/29 17:55:41 momjian Exp $
+ *       $Header: /cvsroot/pgsql/src/backend/utils/init/Attic/findbe.c,v 1.25 2001/10/29 18:06:54 momjian Exp $
  *
  *-------------------------------------------------------------------------
  */
@@ -103,7 +103,8 @@ ValidateBinary(char *path)
                if (pwp->pw_gid == buf.st_gid)
                        ++in_grp;
                else if (pwp->pw_name &&
-                                (gp = getgrgid(buf.st_gid)) != NULL)
+                                (gp = getgrgid(buf.st_gid)) != NULL &&
+                                gp->gr_mem != NULL)
                {
                        for (i = 0; gp->gr_mem[i]; ++i)
                        {