home *** CD-ROM | disk | FTP | other *** search
- Patch #: 22
- Priority: MEDIUM
- Subject: Patch #14 causes malloc mixups on "rn -c"
- >From: dsp@ptsfa.UUCP (David St. Pierre), landauer@drivax.UUCP (Doug Landauer)
-
- 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 free().
- This can confuse malloc if there is more than one newsgroup with
- expired articles to account for.
-
- Fix: From rn, say "| patch -d DIR", where DIR is your rn source directory.
- Outside of rn, say "cd DIR; patch <thisarticle". If you don't have
- the patch program, apply the following by hand, or get patch.
-
- If patch indicates that patchlevel is the wrong version, you may need
- to apply one or more previous patches, or the patch may already
- have been applied. See the patchlevel file to find out what has or
- has not been applied. In any event, don't continue with the patch.
-
- Index: patchlevel
- Prereq: 21
- 1c1
- < Patch #: 21
- ---
- > Patch #: 22
-
- Index: rcln.c
- Prereq: 4.3
- *** rcln.c.old Tue Jul 23 17:40:30 1985
- --- rcln.c Tue Jul 23 17:40:33 1985
- ***************
- *** 1,4
- ! /* $Header: rcln.c,v 4.3 85/05/01 11:45:36 lwall Exp $
- *
- * $Log: rcln.c,v $
- * Revision 4.3 85/05/01 11:45:36 lwall
-
- --- 1,4 -----
- ! /* $Header: rcln.c,v 4.3.1.2 85/07/23 17:39:08 lwall Exp $
- *
- * $Log: rcln.c,v $
- * Revision 4.3.1.2 85/07/23 17:39:08 lwall
- ***************
- *** 1,6
- /* $Header: rcln.c,v 4.3 85/05/01 11:45:36 lwall Exp $
- *
- * $Log: rcln.c,v $
- * Revision 4.3 85/05/01 11:45:36 lwall
- * Baseline for release with 4.3bsd.
- *
-
- --- 1,12 -----
- /* $Header: rcln.c,v 4.3.1.2 85/07/23 17:39:08 lwall Exp $
- *
- * $Log: rcln.c,v $
- + * Revision 4.3.1.2 85/07/23 17:39:08 lwall
- + * Oops, was freeing a static buf on -c in checkexpired.
- + *
- + * Revision 4.3.1.1 85/05/10 11:37:08 lwall
- + * Branch for patches.
- + *
- * Revision 4.3 85/05/01 11:45:36 lwall
- * Baseline for release with 4.3bsd.
- *
- ***************
- *** 426,432
- (MEM_SIZE)(rcnums[ngnum] + strlen(newnum) + 1));
- }
- else {
- ! free(rcline[ngnum]);
- rcline[ngnum] = mbuf;
- }
-
-
- --- 432,439 -----
- (MEM_SIZE)(rcnums[ngnum] + strlen(newnum) + 1));
- }
- else {
- ! if (!checkflag)
- ! free(rcline[ngnum]);
- rcline[ngnum] = mbuf;
- }
-
-