macget fix

Info-Mac discussion from 1984 - 2002.
Locked
User avatar
Info-Mac
Administrator
Posts: 13716
Joined: December 21st, 1988, 11:00 am

macget fix

Post by Info-Mac » August 27th, 1984, 9:52 pm

Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP
Posting-Version: version B 2.10 UW 5/3/83; site uw-beaver
Path: utzoo!watmath!clyde!burl!ulysses!cbosgd!ucbvax!ucbcad!tektronix!uw-beaver!info-mac
From: [email protected]
Newsgroups: fa.info-mac
Subject: macget fix
Message-ID:
Date: Fri, 6-Jul-84 01:23:47 EDT
Article-I.D.: uw-beave.1006
Posted: Fri Jul 6 01:23:47 1984
Date-Received: Sun, 1-Jul-84 07:10:09 EDT
Sender: [email protected]
Organization: U of Washington Computer Science
Lines: 26

From: [email protected] (Dan Winkler)
Here's a fix to make the -u option of macget work. It was
incrementing a pointer before the cr to nl translation
but it should be incremented after.


diff macget.c macget2.c
337c337
cksum += *bp;
339a340
> bp++;

So now the code reads:

for (i = 0; i < count; i++) {
cksum += *bp;
if (txtmode && *bp == '\r')
*bp = '\n';
bp++;
}



Dan.
Locked