signal module?

Martin v. Löwis martin.vonloewis at hpi.uni-potsdam.de
Thu Mar 27 04:55:49 EST 2003


> I'm using threads, so I'd like ctrl-c to actually terminate the
> program. If my memory serves me, ctrl-c is SIGINT, so in my code, in
> the main thread, I write:

Notice that Python already binds SIGINT, to install a handler that raises
a KeyboardInterrupt.

Regards,
Martin






More information about the Python-list mailing list