X-Spam-Check-By: sourceware.org Date: Wed, 15 Feb 2006 18:28:01 +0100 From: Samuel Thibault To: cygwin AT cygwin DOT com Subject: Re: How can I detect cygwin windows closing Message-ID: <20060215172801.GB4216@implementation.labri.fr> Mail-Followup-To: cygwin AT cygwin DOT com References: Mime-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: User-Agent: Mutt/1.5.11 X-IsSubscribed: yes Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm Precedence: bulk List-Unsubscribe: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner AT cygwin DOT com Mail-Followup-To: cygwin AT cygwin DOT com Delivered-To: mailing list cygwin AT cygwin DOT com 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/