Subject: Re: quick question to C programmers
To: None <tech-pkg@netbsd.org>
From: Richard Rauch <rkr@olib.org>
List: tech-pkg
Date: 04/07/2005 12:04:42
The code looks wrong on the face of it.  Either:

FILE *LayYYin = stdin;

...or:

FILE **LayYYin = {stdin};

...would be fine.  The former creates a C stdio FILE pointer and
initializes it of course, while the latter creates a 1-element
array of FILE pointers (well, okay, apointer to pointer(s) FILE...).
In isolation, I'd say that it seems easier for someone to have
accidentally produced the cited code if they'd *meant* the second
of the above two.

On the other hand, I can only see one place (via grep) where this
variable is used, and there it is used as a regular FILE pointer.
I don't see how, offhand, the code as-it-is can work.  (shrug)

-- 
  "I probably don't know what I'm talking about."  http://www.olib.org/~rkr/