diff options
author | Ilya Zakharevich <ilya@math.berkeley.edu> | 2006-12-17 16:55:19 -0800 |
---|---|---|
committer | Rafael Garcia-Suarez <rgarciasuarez@gmail.com> | 2006-12-18 10:49:15 +0000 |
commit | 2563cec55ae473562ff3ccda41cd10289db419be (patch) | |
tree | ecc52eff5126281981cf3d3b8560f69804eb90b5 /mg.c | |
parent | c944940bcb88dd1d6b36277c4a80ccce87a5f9b8 (diff) | |
download | perl-2563cec55ae473562ff3ccda41cd10289db419be.tar.gz |
OS/2: survive SIGCHLD
Message-ID: <20061218085519.GA14893@powdermilk.math.berkeley.edu>
plus a perldiag entry for the new error,
"Maximal count of pending signals (%s) exceeded"
p4raw-id: //depot/perl@29577
Diffstat (limited to 'mg.c')
-rw-r--r-- | mg.c | 8 |
1 files changed, 7 insertions, 1 deletions
@@ -1290,6 +1290,10 @@ Perl_magic_clearsig(pTHX_ SV *sv, MAGIC *mg) return 0; } +#ifndef SIG_PENDING_DIE_COUNT +# define SIG_PENDING_DIE_COUNT 120 +#endif + static void S_raise_signal(pTHX_ int sig) { @@ -1297,7 +1301,9 @@ S_raise_signal(pTHX_ int sig) /* Set a flag to say this signal is pending */ PL_psig_pend[sig]++; /* And one to say _a_ signal is pending */ - PL_sig_pending = 1; + if (++PL_sig_pending >= SIG_PENDING_DIE_COUNT) + Perl_croak(aTHX_ "Maximal count of pending signals (%lu) exceeded", + (unsigned long)SIG_PENDING_DIE_COUNT); } Signal_t |