[4296] in Athena Bugs

home help back first fref pref prev next nref lref last post

ls can dump core

daemon@ATHENA.MIT.EDU (John Carr)
Sat Feb 24 09:09:20 1990

To: bugs@ATHENA.MIT.EDU
Date: Sat, 24 Feb 90 09:09:06 EST
From: John Carr <jfc@ATHENA.MIT.EDU>

ls can dump core if asked to list 3 files which have gids congruent mod 128
(and probably under other circumstances). Here is the fix (I have tested this):

*** /source/athena/bin/ls/get.c	Thu Nov 16 06:13:35 1989
--- get.c	Sat Feb 24 09:02:05 1990
***************
*** 78,84 ****
    static int lastgid = UNK_UID;
    static struct gncache { gid_t gid;
  			  char name[NMAX+1];
! 			} nc[2][NUID];
    static char lastgroup[NMAX+1];
  
    if(lastgid == gid)
--- 78,84 ----
    static int lastgid = UNK_UID;
    static struct gncache { gid_t gid;
  			  char name[NMAX+1];
! 			} nc[2][NGID];
    static char lastgroup[NMAX+1];
  
    if(lastgid == gid)



home help back first fref pref prev next nref lref last post