develooper Front page | perl.perl5.porters | Postings from June 2019

Re: [perl #122112] refcnt: fd -1 < 0 with MIME::Lite

Thread Previous | Thread Next
Richard Leach
June 3, 2019 21:36
Re: [perl #122112] refcnt: fd -1 < 0 with MIME::Lite
Message ID:
On Mon, Jun 3, 2019 at 6:43 PM Richard Leach
<> wrote:
> It was definitely fb5e77103dd443cc2112ba14dc665aa5ec072ce6 wot broke it.

That commit broke the test from a smoker's perspective, but it was
heisenbroken on some platforms before that. Prior to that commit,
t/io/pipe.t tests all passed under "make test" or "make test_harness",
but do not if t/ harness or t/TEST are invoked manually. (Many "WTFs"
have been uttered.)
- suggests that GNUroot and Termux have a problem where the parent
process ignores SIGPIPE.

The Termux SSH shell indeed cannot catch SIGPIPE:

  $ trap '' pipe; bash -c 'trap - pipe; for i in {0..9}; do
  > /bin/echo $i; sleep 1; done | dd bs=1 count=10'
  10+0 records in
  10+0 records out
  10 bytes copied, 4.20389 s, 0.0 kB/s
  /bin/echo: write error: Broken pipe
  /bin/echo: write error: Broken pipe
  /bin/echo: write error: Broken pipe
  /bin/echo: write error: Broken pipe
  /bin/echo: write error: Broken pipe

I'm not sufficiently familiar with the process model to know how
running the tests via 'make' seems to work. Should there be something
we can try to get the SIGPIPE tests working here?

I've run out of time this evening, but options otherwise seem to be:
(1) skip some tests if ($^O eq 'android'), although that wouldn't help
anyone building under GNUroot
(2) run a check like the above for SIGPIPE behaviour, then skip tests
if necessary


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