Mato, On Wed, Mar 10, 2010 at 1:52 PM, Martin Lucina <[email protected]> wrote: > Brian, > > [email protected] said: >> At that point, Python raised KeyboardError (the default sig handler >> raises that for ctrl-C). This simple experiment show that: >> >> 1. Python's signal handler is still installed and working properly. >> 2. When blocking on zmq_recv, the Python interpreter is "not in >> control." (the 0MQ C++ code is running) and thus can't respond to the >> signal until it gets control. >> >> Thus, I think the only way of resolving this if 0MQ is making out >> signals in the IO threads. Thoughts? > > What you're saying is that the Python signal handler receives the signal, > queues some kind of internal flag indicating "a signal was received" but > doesn't actually *act on* the signal until the 0MQ C++ code returns to the > Python binding, and the Python binding returns control to the Python > interpreter. > > Do I understand you correctly?
Yes, that is my understanding of what Python is doing. Cheers, Brian > -mato > -- Brian E. Granger, Ph.D. Assistant Professor of Physics Cal Poly State University, San Luis Obispo [email protected] [email protected] _______________________________________________ zeromq-dev mailing list [email protected] http://lists.zeromq.org/mailman/listinfo/zeromq-dev
