Abnormal Interpreter Shutdown
Gabriel Genellina
gagsl-py2 at yahoo.com.ar
Tue Oct 21 05:16:46 EDT 2008
En Tue, 21 Oct 2008 05:07:34 -0200, k3xji <sumerc at gmail.com> escribió:
> I think what I am looking for is SetConsoleCtrlHandler(..) which
> receives signals for CTRL+C and system shutdown. I don't want to take
> the power outage into account because as far as I can see there is no
> portable/simple/reliable way to accomplish that. So, thanks for the
> tip again.
>
> So what is the equivalent of this API in Linux? How can I accomplish
> the same behavior for Linux?
Using signal - see http://linux.die.net/man/7/signal and signal(2)
--
Gabriel Genellina
More information about the Python-list
mailing list