www.delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2000/03/15/01:13:32

Mailing-List: contact cygwin-help AT sourceware DOT cygnus DOT com; run by ezmlm
List-Subscribe: <mailto:cygwin-subscribe AT sourceware DOT cygnus DOT com>
List-Archive: <http://sourceware.cygnus.com/ml/cygwin/>
List-Post: <mailto:cygwin AT sourceware DOT cygnus DOT com>
List-Help: <mailto:cygwin-help AT sourceware DOT cygnus DOT com>, <http://sourceware.cygnus.com/ml/#faqs>
Sender: cygwin-owner AT sourceware DOT cygnus DOT com
Delivered-To: mailing list cygwin AT sourceware DOT cygnus DOT com
Message-Id: <200003150613.BAA01221@mail.bcpl.net>
From: "J. David Bryan" <dbryan AT bcpl DOT net>
Organization: Palomar Corporation
To: cygwin AT sourceware DOT cygnus DOT com
Date: Wed, 15 Mar 2000 01:13:03 -0500
MIME-Version: 1.0
Subject: Re: Permission denied with makeinfo from texinfo-4.0
In-reply-to: <20000315005835.A5528@cygnus.com>
References: <200003150556 DOT AAA28729 AT mail DOT bcpl DOT net>; from dbryan AT bcpl DOT net on Wed, Mar 15, 2000 at 12:56:31AM -0500
X-mailer: Pegasus Mail for Win32 (v3.12c)

On 15 Mar 2000, at 0:58, Chris Faylor wrote:

> Ok.  I've got it.  Sorry.  I obviously lost the thread pretty badly.
> 
> (slinks away)

Must be a late night!  ;-)

To clarify for just a bit on the line ends part, on systems without 
O_BINARY defined, makeinfo will read the texinfo file in one go with a 
single "read" call.  It will then compare the read file size to the size 
returned by "stat".  If they don't match, then makeinfo terminates with an 
error.

Makeinfo actually compiles one of three different read calls, depending on 
a bunch of system defines.  The WIN32-specific version reads one byte at a 
time and so doesn't wind up specifying an invalid buffer.  The generic 
O_BINARY version (into which Cygwin falls) reads all in one go but is aware 
that it might get less bytes than the size of the file would indicate (due 
to \r\n -> \n translations).  However, this call specifies the invalid 
buffer.  The generic non-O_BINARY version also reads all in one go and 
doesn't specify an invalid buffer but demands that the number of bytes read 
equals the file size.

As I noted, the proper solution is to fix the invalid buffer call, but one 
can work around the problem either by defining WIN32 and accepting the 
tradeoffs (slow reads, no $HOME support) or by undefining O_BINARY and 
accepting the tradeoff (no \r\n support).

                                      -- Dave Bryan

--
Want to unsubscribe from this list?
Send a message to cygwin-unsubscribe AT sourceware DOT cygnus DOT com

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019