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
99c160b5
Kaydet (Commit)
99c160b5
authored
Kas 05, 2009
tarafından
Antoine Pitrou
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
Issue #7264: Fix a possible deadlock when deallocating thread-local objects
which are part of a reference cycle.
üst
2537e7a4
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
12 additions
and
3 deletions
+12
-3
_threading_local.py
Lib/_threading_local.py
+5
-3
threading.py
Lib/threading.py
+4
-0
NEWS
Misc/NEWS
+3
-0
No files found.
Lib/_threading_local.py
Dosyayı görüntüle @
99c160b5
...
@@ -218,10 +218,12 @@ class local(_localbase):
...
@@ -218,10 +218,12 @@ class local(_localbase):
key
=
object
.
__getattribute__
(
self
,
'_local__key'
)
key
=
object
.
__getattribute__
(
self
,
'_local__key'
)
try
:
try
:
threads
=
list
(
threading
.
enumerate
())
# We use the non-locking API since we might already hold the lock
# (__del__ can be called at any point by the cyclic GC).
threads
=
threading
.
_enumerate
()
except
:
except
:
# If enumerat
e fails, as it seems to do during
# If enumerat
ing the current threads fails, as it seems to do
# shutdown, we'll skip cleanup under the assumption
#
during
shutdown, we'll skip cleanup under the assumption
# that there is nothing to clean up.
# that there is nothing to clean up.
return
return
...
...
Lib/threading.py
Dosyayı görüntüle @
99c160b5
...
@@ -810,6 +810,10 @@ def activeCount():
...
@@ -810,6 +810,10 @@ def activeCount():
active_count
=
activeCount
active_count
=
activeCount
def
_enumerate
():
# Same as enumerate(), but without the lock. Internal use only.
return
_active
.
values
()
+
_limbo
.
values
()
def
enumerate
():
def
enumerate
():
with
_active_limbo_lock
:
with
_active_limbo_lock
:
return
_active
.
values
()
+
_limbo
.
values
()
return
_active
.
values
()
+
_limbo
.
values
()
...
...
Misc/NEWS
Dosyayı görüntüle @
99c160b5
...
@@ -426,6 +426,9 @@ Core and Builtins
...
@@ -426,6 +426,9 @@ Core and Builtins
Library
Library
-------
-------
- Issue #7264: Fix a possible deadlock when deallocating thread-local objects
which are part of a reference cycle.
- Issue #7211: Allow 64-bit values for the `ident` and `data` fields of kevent
- Issue #7211: Allow 64-bit values for the `ident` and `data` fields of kevent
objects on 64-bit systems. Patch by Michael Broghton.
objects on 64-bit systems. Patch by Michael Broghton.
...
...
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