<< Previous Message Main Index Next Message >>
<< Previous Message in Thread This Month Next Message in Thread >>
Date   : Sun, 17 Aug 1986 07:41:00 MDT
From   : Keith Petersen <W8SDZ@SIMTEL20.ARPA>
Subject: Bug in CP/M UUENCODE fixed

Several weeks ago UUENCODE and UUDECODE, written in Turbo Pascal for
use on CP/M, were posted to Info-Cpm (net.micro.cpm).  A bug in
UUENCODE caused one additional "garbage" record to be included at the
end of the file.  This caused the resultant UUDECODEd file to be one
record longer than the original file and prevented error checking with
CRCK.  The fixed area is shown below (thanks to Bernie Eiben):

  procedure encode1;

    begin {encode1};
      if numbytes = bytesperhunk then flushhunk;
      endofinfile := not (getbyte(hunk[numbytes]));
      if not endofinfile then numbytes := succ(numbytes)  {No succ at EOF -BE}
    end; {encode1}

I do hope we don't end up using uuencode/uudecode when other means are
available for doing file transfers.  We CP/M'ers have maintained a
relatively error-free environment over the years.  The
Uuencode/Uudecode system contains NO CRC or CHECKSUM error checking!
If we were to add that, the programs would no longer be compatible
with Unix versions.  I suggest that anyone sending files using this
program include a CRC list in the introduction so readers can check
the decoded files with my CRCK program.  CRCK, by the way, is also
available for Unix.  It's in PD:<UNIX.CPM>CRCK2.C here at SIMTEL20.

--Keith Petersen
Arpa: W8SDZ@SIMTEL20.ARPA
uucp: {ihnp4,allegra,cmcl2,dual,decvax,mcnc,mcvax,vax135}!seismo!w8sdz
GEnie Mail: W8SDZ
RCP/M Royal Oak: 313-759-6569
<< Previous Message Main Index Next Message >>
<< Previous Message in Thread This Month Next Message in Thread >>