Locking blockl to a people on a similar group / naming locks

Paul Rubin http
Wed Jan 21 05:06:52 EST 2009


"Diez B. Roggisch" <deets at nospam.web.de> writes:
> In python 2.5 and upwards, you can write this safer
> from __future__ import with_statement # only needed for py2.5
> with myInstance.lock:
>    ... critical section

Good point!



More information about the Python-list mailing list