jeffb@leia.UUCP (10/04/86)
Note: My mail to Larry may have gone to the bit bucket, so here is attempt number two. Description: Patch #14 attempted to speed up "rn -c" by using a static buffer instead of an malloc'ed one. Unfortunately, buried deep down in a routine called checkexpired there was an unguarded call to saferealloc(), which calls realloc(). This confused realloc() to no end, since it didn't know how large the area being realloc'ed was originally; or rather, it thought it knew, but it really didn't. *** rcln.c.new Fri Sep 12 21:53:10 1986 --- rcln.c.old Fri Sep 12 21:52:49 1986 *************** *** 427,433 *t++ = ','; strcpy(t,s); } ! if (!checkflag && mbuf == rcline[ngnum]) { rcline[ngnum] = saferealloc(rcline[ngnum], (MEM_SIZE)(rcnums[ngnum] + strlen(newnum) + 1)); } --- 427,433 ----- *t++ = ','; strcpy(t,s); } ! if (mbuf == rcline[ngnum]) { rcline[ngnum] = saferealloc(rcline[ngnum], (MEM_SIZE)(rcnums[ngnum] + strlen(newnum) + 1)); } -- Jeff Beachy AIM, Tektronix, Inc., Wilsonville, OR jeffb@tekecs.GWD.TEK.COM -or- {ihnp4, decvax, ucbvax}!tektronix!tekecs!jeffb