How can I detect cygwin windows closing

Samuel Thibault samuel.thibault@ens-lyon.org
Wed Feb 15 17:29:00 GMT 2006


Hi,

Wilfried Fauvel, le Wed 15 Feb 2006 18:18:49 +0100, a écrit :
> I have made a console apps, and I would like to know if it's possible to detect when the user click on the 'X' of the term window ?
> I am catching SIGINT, SIGTERM and SIGKILL signals, but it does not seen to be enough.

See SetConsoleCtrlHandler() and friends. I however never found a way to
avoid being killed anyway, even by trying to detach from the console.

Regards,
Samuel

--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Problem reports:       http://cygwin.com/problems.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/



More information about the Cygwin mailing list