Path: utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!csd4.milw.wisc.edu!bionet!ig!ames!elroy!peregrine!ccicpg!conexch!bob From: bob@conexch.UUCP (Bob Best) Newsgroups: alt.sources Subject: Re: A unix version of unzip11 that was posted a few days ago. Summary: minor bug fix Message-ID: <27481@conexch.UUCP> Date: 9 Apr 89 17:51:20 GMT References: <3461@vice.ICO.TEK.COM> Reply-To: bob@dhw68k.cts.com (Bob Best) Organization: The Consultants' Exchange, Orange County, CA Lines: 45 The following patch fixes a bug that was causing an extra (null) byte to be appended to some files on extraction. The type declaration of parameter 's' in get_string() has also been fixed. *** unzipbsd.c~ Sun Apr 9 10:33:47 1989 --- unzipbsd.c Sun Apr 9 10:39:40 1989 *************** *** 267,273 **** get_string(len, s) int len; ! char *s[]; { read(zipfd,s,len); s[len] = 0; --- 267,273 ---- get_string(len, s) int len; ! char *s; { read(zipfd,s,len); s[len] = 0; *************** *** 811,817 **** while ((!zipeof)) { ReadByte(&b); ! OutByte(b); } } break; --- 811,818 ---- while ((!zipeof)) { ReadByte(&b); ! if (!zipeof) /* bob@dhw68k.cts.com */ ! OutByte(b); } } break; -- Bob Best bob@dhw68k.cts.com