mirror of
https://github.com/python/cpython.git
synced 2025-10-28 09:10:36 +00:00
#10846: fix typo.
This commit is contained in:
parent
b30111f29e
commit
a572476a2a
1 changed files with 3 additions and 3 deletions
|
|
@ -719,9 +719,9 @@ waiting until some other thread calls :meth:`release`.
|
||||||
^^^^^^^^^^^^^^^^^^^^^^^^^^
|
^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||||
|
|
||||||
Semaphores are often used to guard resources with limited capacity, for example,
|
Semaphores are often used to guard resources with limited capacity, for example,
|
||||||
a database server. In any situation where the size of the resource size is
|
a database server. In any situation where the size of the resource is fixed,
|
||||||
fixed, you should use a bounded semaphore. Before spawning any worker threads,
|
you should use a bounded semaphore. Before spawning any worker threads, your
|
||||||
your main thread would initialize the semaphore::
|
main thread would initialize the semaphore::
|
||||||
|
|
||||||
maxconnections = 5
|
maxconnections = 5
|
||||||
...
|
...
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue