Antoine Pitrou <pit...@free.fr> added the comment:

You are just having wrong expectations. Releasing a lock doesn't guarantee that 
any other thread waiting on it will be scheduled preemptively. So, if you 
re-acquire the lock immediately, the other thread will not necessarily have had 
the opportunity of running at all. Whether or not threads do get switched at 
that point is highly system-dependent.

There are many synchronisation primitives you can use (locks, events, queues, 
condition variables...), each for a different purpose. I suggest you post on 
comp.lang.python if you want more help on the subject.

----------
resolution:  -> invalid
status: open -> closed

_______________________________________
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue8055>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to