[Mono-dev] Control-C handler

Miguel de Icaza miguel at novell.com
Thu Dec 20 14:16:03 EST 2007


> You can use signal(2), which is helpfully exposed by Mono.Posix.dll.
> See the attached program.

This actually would corrupt the application state, because the C-c
handler will run the entire JIT at that point and this happens in the
same thread as the executing thread.

A better approach would be to hook this up in C, and set a flag from C
(this could be setting a value in managed land that you can poll)

More information about the Mono-devel-list mailing list