Re: gzip: input file size weirdness.
William Fletcher <[email protected]>
| Newsgroups | gmane.os.netbsd.help |
|---|---|
| Message-ID | <[email protected]> |
Thanks.
I'll probably just install pkgsrc's gzip. At the moment the machine is actually
down over the holidays, since this morning, so now I can't fix it :(
On Tue, Dec 12, 2006 at 08:25:44AM -0500, Greg Troxel wrote:
> gzip: input file size >= 4GB cannot be saved: Inappropriate ioctl for device
>
> The 'inappropriate ioctl' message is spurious (what errno happened to
> be). I have the following old local patch, which points out the issue
> (and changes to fix this in a different way than someone else fixed
> it). Look for this in gzip and comment out the maybe_warn. I don't
> know if this has been pulled up to netbsd-2.
>
>
> Index: gzip.c
> ===================================================================
> RCS file: /cvsroot/src/usr.bin/gzip/gzip.c,v
> retrieving revision 1.79
> diff -u -r1.79 gzip.c
> --- gzip.c 22 Nov 2005 09:07:03 -0000 1.79
> +++ gzip.c 22 Nov 2005 13:24:57 -0000
> @@ -639,9 +639,15 @@
> (int)(in_tot >> 24) & 0xff);
> if (i != 8)
> maybe_err("snprintf");
> -#if 0
> - if (in_tot > 0xffffffff)
> - maybe_warn("input file size >= 4GB cannot be saved");
> +#ifndef SMALL
> + if (in_tot > 0xffffffff && vflag)
> + /*
> + * RFC1952 specifies that ISIZE is modulo 2^32, so
> + * don't note this unless in verbose mode. (Note that
> + * amanda reports any such output, which is
> + * distracting and therefore harmful.)
> + */
> + warnx("input file size >= 4GB stored modulo 2^32");
> #endif
> if (write(out, outbufp, i) != i) {
> maybe_warn("write");
>
--
Omina Solutions | http://omina.co.za | (012) Ph. 664-2480 F. 664-2474
signature.asc
(application/pgp-signature, 186 B)
-----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.5 (NetBSD) iD8DBQFFfrQJ0o1hk/SHCkoRAoubAJ9iUsI3fMyg/thtUH+YtIQ9xXZcFQCcD4L6 tVCbTaGFnD2ToFaabhfyTng= =UgXv -----END PGP SIGNATURE-----