How to force a thread to stop
Carl J. Van Arsdall
cvanarsdall at mvista.com
Wed Jul 26 20:38:06 EDT 2006
Gerhard Fiedler wrote:
> On 2006-07-26 19:08:44, Carl J. Van Arsdall wrote:
>
>
>> Also, threading's condition and event constructs are used a lot
>> (i talk about it somewhere in that thing I wrote). They are easy to use
>> and nice and ready for me, with a server wouldn't I have to have things
>> poll/wait for messages?
>>
>
> How would a thread receive a message, unless it polls some kind of queue or
> waits for a message from a queue or at a semaphore? You can't just "push" a
> message into a thread; the thread has to "pick it up", one way or another.
>
> Gerhard
>
>
Well, I guess I'm thinking of an event driven mechanism, kinda like
setting up signal handlers. I don't necessarily know how it works under
the hood, but I don't poll for a signal. I setup a handler, when the
signal comes, if it comes, the handler gets thrown into action. That's
what I'd be interesting in doing with threads.
-c
--
Carl J. Van Arsdall
cvanarsdall at mvista.com
Build and Release
MontaVista Software
More information about the Python-list
mailing list