A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://mail.python.org/pipermail/python-dev/2006-July/067836.html below:

[Python-Dev] Testing Socket Timeouts patch 1519025

[Python-Dev] Testing Socket Timeouts patch 1519025"Martin v. Löwis" martin at v.loewis.de
Sun Jul 30 09:42:14 CEST 2006
Tony Nelson schrieb:
> Hmm, OK, darn, thanks.  MSWindows does allow users to press Ctl-C to send a
> KeyboardInterrupt, so it's just too bad if I can't find a way to test it
> from a script.

You can use GenerateConsoleCtrlEvent to send Ctrl-C to all processes
that share the console of the calling process.

> BTW, I picked SIGALRM because I could do it all with one thread.  Reading
> POSIX, ISTM that if I sent the signal from another thread, it would bounce
> off that thread to the main thread during the call to kill(), at which
> point I got the willies.  OTOH, if kill() is more widely available than
> alarm(), I'll give it a try, but going by the docs, I'd say it isn't.

Indeed, alarm should be available on any POSIX system.

Regards,
Martin
More information about the Python-Dev mailing list

RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4