[Python-ideas] Should stdlib provide something to properly handle SIGINT/SIGTERM signals?
Ethan Furman
ethan at stoneleaf.us
Wed Dec 28 06:40:23 CET 2011
Giampaolo Rodolà wrote:
> The behavior I would expect when facing such a problem is the
> following:
>
> * I want my exit function to always be called, no matter what
> o I'm aware that it won't be called in case of SIGKILL or
> os._exit() though
> * I do not want to override previously registered signal handlers
> (if any)
> o Instead I want the old handler to be called fist and my
> exit function to be called last
Aren't nested handlers usually called in a last-in/first-out manner?
~Ethan~
More information about the Python-ideas
mailing list