Fix for GutHub issue #64 - vvp interrupt/continue in Windows.

Windows implements the original UNIX semantics for signal(), which
means you have to re-establish the signal handler each time a signal
is caught.
This commit is contained in:
Martin Whitaker 2015-05-15 22:30:03 +01:00
parent 7442c14689
commit b6304129fa
1 changed files with 6 additions and 0 deletions

View File

@ -531,6 +531,12 @@ bool schedule_stopped(void)
*/
extern "C" void signals_handler(int)
{
#ifdef __MINGW32__
// Windows implements the original UNIX semantics for signal,
// so we have to re-establish the signal handler each time a
// signal is caught.
signal(SIGINT, &signals_handler);
#endif
schedule_stopped_flag = true;
}