RE: perl won't alarm?

2011-02-23 Thread Jan Dubois
On Wed, 23 Feb 2011, Robert W Weaver wrote: > Is there a way I can protect my routine from hanging system calls? alarm() will not interrupt a blocking system call on Windows. If you want to timeout on subprocesses, then you may want to look at Win32::Job. Cheers, -Jan ___

perl won't alarm?

2011-02-23 Thread Robert W Weaver
I have code that executes an external command, vis: eval { local $SIG{ALRM} = sub { die "alarm\n" }; alarm $TIMEOUT; $text = `$pre_command$host $post_command` || ( $connectOk = 0 ); alarm 0; $errStr = $^E; }; The command hangs for a reason I don't understand (its a PsExec

RE: spurious deaths in script execution due to read-only Config?

2011-02-23 Thread Brian Raven
-Original Message- From: perl-win32-users-boun...@listserv.activestate.com [mailto:perl-win32-users-boun...@listserv.activestate.com] On Behalf Of Christian Walde Sent: 23 February 2011 15:57 To: perl-win32-users@listserv.activestate.com Subject: Re: spurious deaths in script execution due

Re: spurious deaths in script execution due to read-only Config?

2011-02-23 Thread Christian Walde
On Wed, 23 Feb 2011 16:33:49 +0100, Brian Raven wrote: >>> I remembered this morning that there is a bug tracker for ActivePerl, >>> started to write up an error report and in doing so ended up >>> formulating a possible for for ActiveState: >>> http://bugs.activestate.com/show_bug.cgi?id=89447 >

RE: spurious deaths in script execution due to read-only Config?

2011-02-23 Thread Brian Raven
-Original Message- From: perl-win32-users-boun...@listserv.activestate.com [mailto:perl-win32-users-boun...@listserv.activestate.com] On Behalf Of Chris Wagner Sent: 23 February 2011 14:25 To: perl-win32-users@listserv.activestate.com Subject: Re: spurious deaths in script execution due to

Re: spurious deaths in script execution due to read-only Config?

2011-02-23 Thread Chris Wagner
It's the standard behavior of Perl. use Data::Dump "pp"; %a = qw/x 1 y 1 z 1/; grep { $_ } $a{bob}; pp %a; ^D ("y", 1, "bob", undef, "x", 1, "z", 1) At 02:18 PM 2/22/2011 +0100, Christian Walde wrote: >On Tue, 22 Feb 2011 13:46:55 +0100, Chris Wagner wrote: >> At 08:54 PM 2/21/2011 +0100, Chri