#include #include int sigint_received=0; static void stopall() { printf("SIGINT RECEIVED: aborting eval\n"); sigint_received=1; } int stopped() { return sigint_received; } void set_intr() { signal(SIGINT, stopall); # ifdef DEBUG printf("SIGINT armed.\n"); # endif }