Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Posting-Version: version B 2.10.2 9/18/84; site brunix.UUCP Path: utzoo!watmath!clyde!burl!ulysses!brunix!ddj From: ddj@brunix.UUCP (Dave Johnson) Newsgroups: net.micro.mac Subject: new version of xbin -- fix for checksum bug Message-ID: <10565@brunix.UUCP> Date: Tue, 1-Oct-85 01:42:21 EDT Article-I.D.: brunix.10565 Posted: Tue Oct 1 01:42:21 1985 Date-Received: Thu, 3-Oct-85 05:19:10 EDT Distribution: net Organization: Brown University Computer Science Lines: 44 After an hour or two of bug-chasing, I tracked down the cause of the recently reported checksum errors in "xbin". The problem showed up when there was a run of three or more 0x90 characters. The sequence 0x90NN indicates that the previous character should be repeated NN times, with the exception that 0x9000 specifies a literal 0x90. The bug was when a literal 0x90 was supposed to be repeated, the character before the 0x90 was used instead. So where 2090009003 should have produced a 20 and 3- 90's, it came out 20 90 20 20. Here is the fix to version 2.1, if you can't get 2.3 right away: *** xbin.c Tue Oct 1 01:16:20 1985 --- xbin.c.fixed Tue Oct 1 01:17:21 1985 *************** *** 545,550 if ((rep = getq_raw()) == EOF) return EOF; if (rep == 0) { return RUNCHAR; } else { --- 545,551 ----- if ((rep = getq_raw()) == EOF) return EOF; if (rep == 0) { + lastc = RUNCHAR; return RUNCHAR; } else { Source for version 2.3 (there was no 2.2) is in net.sources.mac and should be archived on [sumex]unix-xbin.shar. In addition to the above-described bug fix, this version includes fixes people have sent me during the last 6 months or so, and the performance improvements done by Dan LaLiberte at UIUC (sorry for the delay...). Dave Johnson Brown University Computer Science ddj%brown@csnet-relay.ARPA {ihnp4,decvax,allegra,ulysses,linus}!brunix!ddj