p4raw-id: //depot/perl@6108
Signal_t
Perl_sighandler(int sig)
{
+#if defined(WIN32) && defined(PERL_IMPLICIT_CONTEXT)
+ dTHXoa(PL_curinterp); /* fake TLS, because signals don't do TLS */
+#else
dTHX;
+#endif
dSP;
GV *gv = Nullgv;
HV *st;
U32 flags = 0;
I32 o_save_i = PL_savestack_ix;
XPV *tXpv = PL_Xpv;
+
+#if defined(WIN32) && defined(PERL_IMPLICIT_CONTEXT)
+ PERL_SET_THX(aTHXo); /* fake TLS, see above */
+#endif
if (PL_savestack_ix + 15 <= PL_savestack_max)
flags |= 1;
# define aTHXo aTHX
# define aTHXo_ aTHX_
# define dTHXo dTHX
+# define dTHXoa(x) dTHXa(x)
#endif
#ifndef pTHXx
#ifndef ___PerlHost_H___
#define ___PerlHost_H___
+#include <signal.h>
#include "iperlsys.h"
#include "vmem.h"
#include "vdir.h"
Sighandler_t
PerlProcSignal(struct IPerlProc* piPerl, int sig, Sighandler_t subcode)
{
- return 0;
+ return signal(sig, subcode);
}
#ifdef USE_ITHREADS