in reply to odd interaction of Net::SSH::Expect and open
Not a complete explanation... but my suspicion is that it has to do with Net::SSH::Expect globally setting $SIG{CHLD}. At least I do get the same error when replacing the use Net::SSH::Expect; in your code with
BEGIN { package Net::SSH::Expect; use POSIX qw(:signal_h WNOHANG); $SIG{CHLD} = \&reapChild; sub reapChild { do {} while waitpid(-1,WNOHANG) > 0; } }
(which is extracted as is from Net::SSH::Expect)
When I localize the handler
local $SIG{CHLD} = \&reapChild;
things do work for me... (i.e. there's no interaction any longer).
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: odd interaction of Net::SSH::Expect and open
by danmcb (Monk) on Oct 17, 2007 at 11:14 UTC | |
by bnegrao (Initiate) on Apr 19, 2008 at 15:41 UTC |