Re: [Orbit-python-list] Catching SIGINT inside orb.run()
Status: Inactive
Brought to you by:
tack
From: Christian R. R. <ki...@as...> - 2000-11-30 15:38:26
|
On Thu, 30 Nov 2000, Jason Tackaberry wrote: > It looks like the approach would be to release the interpreter lock and > call PyErr_CheckSignals(), and then reestablish the lock. (Look at > operation_skel() in server.c on how to restore/save the lock). Okay, this has been done, easily. However, now that I think of it, it might not be a solution at all: a) I override signal A using signal.signal() b) orb.run() gets called c) Just before actually doing the run() I set a new handler for A that would check PyErr_CheckSignals() I just lost the original handler, no? So what I have to do is either set a default handler for all signals that in turns calls a specific handler for each signal (which I doubt exists in Unix), or save all handlers that came in in a structure and call them accordingly depending on what signal I actually got. Am I lost? Take care, -- /\/\ Christian Reis, Senior Engineer, Async Open Source, Brazil ~\/~ http://async.com.br/~kiko/ | [+55 16] 274 4311 |