#48 Update perldl/pdl signal handling for "safe signals"


In perl versions since 5.8.x the support for signals has changed
to so called "safe signals" where signals are processed only at
times that are safe for the interpreter and program state.

This has the effect of modifying the receipt of signals by
a program such as the PDL interactive shells perldl and
the new pdl2. Signals can be ignored or received in a
delayed fashion. I also see much more varied behavior
between cygwin perl and activestate perl with the new

We need to update the code catching Ctrl-C for the
PDL shells so that they are caught as expected (the
old way) in order to allow the desired usage to
interrupt long-running commands or to break out
of a command entry, etc.

I suggest replacing the $SIG{INT} handler code
by corresponding POSIX::sigaction code. Until
that happens, setting PERL_SIGNALS environment
variable to "unsafe" will set all signal handling to
the pre-5.8.x method.


  • Chris Marshall

    Chris Marshall - 2013-01-02

    Increasing the priority for this since a working PDL shell is important for a good PDL user experience.

  • Chris Marshall

    Chris Marshall - 2013-01-02
    • priority: 5 --> 6

Get latest updates about Open Source Projects, Conferences and News.

Sign up for the SourceForge newsletter:

No, thanks