threads+CNI+SIGINT
Jeff Sturm
jsturm@sigma6.com
Mon Mar 27 09:03:00 GMT 2000
Oskar Liljeblad wrote:
> If I initialize ncurses natively in some object, I need to either
> have the user manually restore the terminal, or do it during
> finalization. I prefer the latter because it is easy to write buggy
> code that never cleans up. (But it is also easy to write code that
> always cleans up - except if the program wa killed by SIGINT/SIGTERM.)
Don't use finalization for this. Handling SIGINT is a problem that Java
doesn't solve, unfortunately... I've seen enhancement requests for
portable signal handling on JDC but I don't recall if they ever made it
into the core API (maybe in 1.3, I haven't looked).
In a native CNI method, what signal handlers (if any) can I safely
install? Some signals are reserved by boehm-gc and linuxthreads. Is
this documented? (I know, I'm too lazy/time-crunched to go look for
myself.)
--
Jeff Sturm
jsturm@sigma6.com
More information about the Java
mailing list