Hello,

  I'm having trouble with the common technique (alarm eval{}) to avoid
  blocking operations. The die message is always going to the browser
  even when trapped by the eval block.

eval {
     local $SIG{ALRM} = sub {die};
     alarm 3;
     open(FIFO,">$fifo");
     alarm 0;
};
if ($@) {
   debug("Cliente ausente...");
   close(FIFO);
} else {
  print FIFO ">TERM";
  close(FIFO);
}

  The alarm is being called and the debug message is print but in the
  browser I get the embperl message about the die:

  [1485]ERR: 24: Line 104: Error in Perl code: Died at ...

Any clues or wokarounds?

Thanks in advance.

Luiz Fernando B. Ribeiro


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to