[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
Re: perl bug? weird ctrl-z behaviour when piping from tin through perl
On 2009/09/09 19:35, Thomas Klausner wrote:
> Sometimes I pipe articles in tin(1) through a perl script that parses
> the output, does something and pipes it into less; when I quit less
> I'm back in tin and everything is fine.
> However, when I press ctrl-z (happens more often than I'd think) the
> terminal ends up in a strange state. The output is
> Stopped. Type 'fg' to restart tin
> but I have no shell:
> entering "fg" doesn't take me back to tin. Killing the perl and/or
> less processes doesn't help either, nor does pressing 'q' (as command
> for less or tin).
> A tin developer analysed the behaviour of tin for me:
> before popen(), tin does (feed.c:feed_articles() ~ line 616)
> and after pclose() (feed.c:feed_articles() ~ line 855)
> SIGTSTP causes (signal.c:handle_suspend())
> kill(0, SIGSTOP);
> The developer claims that the double reset_shell_mode shouldn't hurt
> and that this looks ok (I think so as well).
> He reduced my test case to
> and pressing ^Z, which works nicely, however piping through
> perl -ne 'print $_;'|less
> and pressing ^Z confuses perl. This looks like a perl problem.
> Can someone shed more light on this?
I don't have any light to shed, just a suggestion of a (better?) place to
ask the question. Try posting a question to <http://perlmonks.org> under
"Seekers of Perl Wisdom" (you can do this without registering on their
site). There are many folks there who know the guts of Perl and/or would
take this as an interesting problem.
Main Index |
Thread Index |