typo; wasn't printing wheel group files
authorKeith Bostic <bostic@ucbvax.Berkeley.EDU>
Thu, 29 Jun 1989 08:20:14 +0000 (00:20 -0800)
committerKeith Bostic <bostic@ucbvax.Berkeley.EDU>
Thu, 29 Jun 1989 08:20:14 +0000 (00:20 -0800)
SCCS-vsn: bin/ls/print.c 5.14

usr/src/bin/ls/print.c

index 1812981..b72d53b 100644 (file)
@@ -19,7 +19,7 @@
  */
 
 #ifndef lint
  */
 
 #ifndef lint
-static char sccsid[] = "@(#)print.c    5.13 (Berkeley) %G%";
+static char sccsid[] = "@(#)print.c    5.14 (Berkeley) %G%";
 #endif /* not lint */
 
 #include <sys/param.h>
 #endif /* not lint */
 
 #include <sys/param.h>
@@ -176,7 +176,7 @@ printgrp(gid)
        register struct ncache *cp;
 
        cp = c_gid + (gid & LSMASK);
        register struct ncache *cp;
 
        cp = c_gid + (gid & LSMASK);
-       if (cp->gid != gid || *cp->name) {
+       if (cp->gid != gid || !*cp->name) {
                /* can't find group, print out number instead */
                if (!(gr = getgrgid(gid))) {
                        (void)printf("%-*u ", UT_NAMESIZE, gid);
                /* can't find group, print out number instead */
                if (!(gr = getgrgid(gid))) {
                        (void)printf("%-*u ", UT_NAMESIZE, gid);