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

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

From:
Nicholas Clark
Date:
May 28, 2004 15:45
Subject:
Re: [perl #29883] Closing file seems to cause a seek operation
Message ID:
20040528224519.GY1147@plum.flirble.org
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
different.

> > (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



nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About