develooper Front page | perl.perl5.porters | Postings from August 2013

[perl #119097] print returning EINTR in 5.14

Thread Previous | Thread Next
From:
Victor Efimov via RT
Date:
August 11, 2013 13:05
Subject:
[perl #119097] print returning EINTR in 5.14
Message ID:
rt-3.6.HEAD-2552-1376226301-1014.119097-15-0@perl.org
ok, so easier just to

skip_all("not supposed to work with stdio")
if (exists $ENV{PERLIO} && $ENV{PERLIO} =~ /stdio/ );

like eintr.t does

On Sun Aug 11 05:55:55 2013, LeonT wrote:
> On Sun, Aug 11, 2013 at 3:18 PM, Victor Efimov via RT
> <perlbug-followup@perl.org> wrote:
> > Also,
> >
> > (1)
> >
> > http://perldoc.perl.org/perlipc.html#Deferred-Signals-%28Safe-Signals%29
> >> the solution is to use the :perlio layer to do IO--at least on those
> > handles that you want to be able to break into with signals.
> >
> > http://perldoc.perl.org/PerlIO.html
> >> The default can be overridden by setting the environment variable
> > PERLIO to a space separated list of layers
> >
> > it seems that the test initially had
> >  binmode $fh, ":perlio";
> 
> binmode $fh, ":perlio" is conceptually nonsensical. You want to
> specify that during open, but that's broken too :-/
> 
> > but PERLIO=stdio overrides this.
> > so phrase "The default can be overridden by setting the environment
> > variable PERLIO" does not look correct. Not only default is overriden,
> > but any atempt to use the layer.
> 
> No, it doesn't. What you're doing is effectively both:
> ":stdio:perlio". This will generally block unless you're reading the
> buffer size(Because :perlio is assuming read sementics underneath it,
> not fread semantics). This is a known issue that can't be fixed (stdio
> just sucks like that).
> 
> You can kind of fix it with a �use open IO => ":pop:perlio";�, it
> isn't pretty but I'm not sure what else would do the trick. PerlIO
> sucks like that.
> 
> Leon
> 




---
via perlbug:  queue: perl5 status: open
https://rt.perl.org:443/rt3/Ticket/Display.html?id=119097

Thread Previous | Thread Next


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