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
d5cfa549
Kaydet (Commit)
d5cfa549
authored
Tem 03, 2006
tarafından
Martin v. Löwis
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
Put method-wrappers into trashcan. Fixes #927248.
üst
ede77f53
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
14 additions
and
1 deletion
+14
-1
test_descr.py
Lib/test/test_descr.py
+8
-0
NEWS
Misc/NEWS
+3
-0
descrobject.c
Objects/descrobject.c
+3
-1
No files found.
Lib/test/test_descr.py
Dosyayı görüntüle @
d5cfa549
...
...
@@ -3966,6 +3966,13 @@ def weakref_segfault():
o
.
whatever
=
Provoker
(
o
)
del
o
def
wrapper_segfault
():
# SF 927248: deeply nested wrappers could cause stack overflow
f
=
lambda
:
None
for
i
in
xrange
(
1000000
):
f
=
f
.
__call__
f
=
None
# Fix SF #762455, segfault when sys.stdout is changed in getattr
def
filefault
():
if
verbose
:
...
...
@@ -4121,6 +4128,7 @@ def notimplemented():
def
test_main
():
weakref_segfault
()
# Must be first, somehow
wrapper_segfault
()
do_this_first
()
class_docstrings
()
lists
()
...
...
Misc/NEWS
Dosyayı görüntüle @
d5cfa549
...
...
@@ -12,6 +12,9 @@ What's New in Python 2.5 beta 2?
Core and builtins
-----------------
- Bug #927248: Recursive method-wrapper objects can now safely
be released.
- Bug #1417699: Reject locale-specific decimal point in float()
and atof().
...
...
Objects/descrobject.c
Dosyayı görüntüle @
d5cfa549
...
...
@@ -892,10 +892,12 @@ typedef struct {
static
void
wrapper_dealloc
(
wrapperobject
*
wp
)
{
_PyObject_GC_UNTRACK
(
wp
);
PyObject_GC_UnTrack
(
wp
);
Py_TRASHCAN_SAFE_BEGIN
(
wp
)
Py_XDECREF
(
wp
->
descr
);
Py_XDECREF
(
wp
->
self
);
PyObject_GC_Del
(
wp
);
Py_TRASHCAN_SAFE_END
(
wp
)
}
static
int
...
...
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