Skip to content
Projeler
Gruplar
Parçacıklar
Yardım
Yükleniyor...
Oturum aç / Kaydol
Gezinmeyi değiştir
C
cpython
Proje
Proje
Ayrıntılar
Etkinlik
Cycle Analytics
Depo (repository)
Depo (repository)
Dosyalar
Kayıtlar (commit)
Dallar (branch)
Etiketler
Katkıda bulunanlar
Grafik
Karşılaştır
Grafikler
Konular (issue)
0
Konular (issue)
0
Liste
Pano
Etiketler
Kilometre Taşları
Birleştirme (merge) Talepleri
0
Birleştirme (merge) Talepleri
0
CI / CD
CI / CD
İş akışları (pipeline)
İşler
Zamanlamalar
Grafikler
Paketler
Paketler
Wiki
Wiki
Parçacıklar
Parçacıklar
Üyeler
Üyeler
Collapse sidebar
Close sidebar
Etkinlik
Grafik
Grafikler
Yeni bir konu (issue) oluştur
İşler
Kayıtlar (commit)
Konu (issue) Panoları
Kenar çubuğunu aç
Batuhan Osman TASKAYA
cpython
Commits
a7425263
Kaydet (Commit)
a7425263
authored
Ara 18, 2011
tarafından
Antoine Pitrou
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Sade Fark
Merge
üst
2bc801c4
6d5f9e73
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
7 additions
and
7 deletions
+7
-7
threading.py
Lib/threading.py
+4
-7
NEWS
Misc/NEWS
+3
-0
No files found.
Lib/threading.py
Dosyayı görüntüle @
a7425263
...
@@ -1068,21 +1068,18 @@ def _after_fork():
...
@@ -1068,21 +1068,18 @@ def _after_fork():
current
=
current_thread
()
current
=
current_thread
()
with
_active_limbo_lock
:
with
_active_limbo_lock
:
for
thread
in
_active
.
values
():
for
thread
in
_active
.
values
():
# Any lock/condition variable may be currently locked or in an
# invalid state, so we reinitialize them.
thread
.
_reset_internal_locks
()
if
thread
is
current
:
if
thread
is
current
:
# There is only one active thread. We reset the ident to
# There is only one active thread. We reset the ident to
# its new value since it can have changed.
# its new value since it can have changed.
ident
=
_get_ident
()
ident
=
_get_ident
()
thread
.
_ident
=
ident
thread
.
_ident
=
ident
# Any condition variables hanging off of the active thread may
# be in an invalid state, so we reinitialize them.
thread
.
_reset_internal_locks
()
new_active
[
ident
]
=
thread
new_active
[
ident
]
=
thread
else
:
else
:
# All the others are already stopped.
# All the others are already stopped.
# We don't call _Thread__stop() because it tries to acquire
thread
.
_stop
()
# thread._Thread__block which could also have been held while
# we forked.
thread
.
_stopped
=
True
_limbo
.
clear
()
_limbo
.
clear
()
_active
.
clear
()
_active
.
clear
()
...
...
Misc/NEWS
Dosyayı görüntüle @
a7425263
...
@@ -100,6 +100,9 @@ Library
...
@@ -100,6 +100,9 @@ Library
- Issue #7502: Fix equality comparison for DocTestCase instances. Patch by
- Issue #7502: Fix equality comparison for DocTestCase instances. Patch by
Cédric Krier.
Cédric Krier.
- Issue #11870: threading: Properly reinitialize threads internal locks and
condition variables to avoid deadlocks in child processes.
- Issue #8035: urllib: Fix a bug where the client could remain stuck after a
- Issue #8035: urllib: Fix a bug where the client could remain stuck after a
redirection or an error.
redirection or an error.
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment