develooper Front page | perl.perl5.porters | Postings from May 2004

Re: [perl #29883] Closing file seems to cause a seek operation

Nicholas Clark
May 28, 2004 15:45
Re: [perl #29883] Closing file seems to cause a seek operation
Message ID:
On Fri, May 28, 2004 at 11:24:55PM +0100, Alan Burlison wrote:
> Nicholas Clark wrote:
> > I had this hunch that it's because you're using exit() (rather than 
> _exit()),
> > and I'd guess that exit is calling fflush(), and that you're hitting the
> > bug in Solaris that fflush() clobbers input streams.
> That particular bug was fixed in Solaris 8, AFAIK, this is something 
> different.

As this behaviour is replicatable in Solaris 10, it has to be something

> > (ie something non-conformant with C89. Yes. C EIGHTY nine. Not C99.
> > Everyone expecting universal C99 conformance any time soon will be
> > disappointed)
> The behaviour exhibited is required by SVID.  It's doing what it is 
> supposed to
> do.

I was meaning the fflush(NULL) behaviour, which seems not to be the cause
here, w.r.t. the C89 comment.

And I wasn't clear - it wasn't a dig at Solaris in particular. It's more
a general frustration that the world sucks, and takes {sometime,maybe,never}
to achieve conformance with standards.

Nicholas Clark Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at | Group listing | About