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
2a4a62ba
Unverified
Kaydet (Commit)
2a4a62ba
authored
Haz 04, 2018
tarafından
Steve Dower
Kaydeden (comit)
GitHub
Haz 04, 2018
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
bpo-33720: Reduces maximum marshal recursion depth on release builds. (GH-7401)
üst
b609e687
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
12 additions
and
2 deletions
+12
-2
test_marshal.py
Lib/test/test_marshal.py
+4
-1
2018-06-04-09-20-53.bpo-33720.VKDXHK.rst
...S.d/next/Windows/2018-06-04-09-20-53.bpo-33720.VKDXHK.rst
+1
-0
marshal.c
Python/marshal.c
+7
-1
No files found.
Lib/test/test_marshal.py
Dosyayı görüntüle @
2a4a62ba
...
@@ -222,7 +222,10 @@ class BugsTestCase(unittest.TestCase):
...
@@ -222,7 +222,10 @@ class BugsTestCase(unittest.TestCase):
# Create a deeply nested structure.
# Create a deeply nested structure.
head
=
last
=
[]
head
=
last
=
[]
# The max stack depth should match the value in Python/marshal.c.
# The max stack depth should match the value in Python/marshal.c.
if
os
.
name
==
'nt'
and
hasattr
(
sys
,
'gettotalrefcount'
):
# BUG: https://bugs.python.org/issue33720
# Windows always limits the maximum depth on release and debug builds
#if os.name == 'nt' and hasattr(sys, 'gettotalrefcount'):
if
os
.
name
==
'nt'
:
MAX_MARSHAL_STACK_DEPTH
=
1000
MAX_MARSHAL_STACK_DEPTH
=
1000
else
:
else
:
MAX_MARSHAL_STACK_DEPTH
=
2000
MAX_MARSHAL_STACK_DEPTH
=
2000
...
...
Misc/NEWS.d/next/Windows/2018-06-04-09-20-53.bpo-33720.VKDXHK.rst
0 → 100644
Dosyayı görüntüle @
2a4a62ba
Reduces maximum marshal recursion depth on release builds.
Python/marshal.c
Dosyayı görüntüle @
2a4a62ba
...
@@ -25,8 +25,14 @@ module marshal
...
@@ -25,8 +25,14 @@ module marshal
* and risks coring the interpreter. When the object stack gets this deep,
* and risks coring the interpreter. When the object stack gets this deep,
* raise an exception instead of continuing.
* raise an exception instead of continuing.
* On Windows debug builds, reduce this value.
* On Windows debug builds, reduce this value.
*
* BUG: https://bugs.python.org/issue33720
* On Windows PGO builds, the r_object function overallocates its stack and
* can cause a stack overflow. We reduce the maximum depth for all Windows
* releases to protect against this.
* #if defined(MS_WINDOWS) && defined(_DEBUG)
*/
*/
#if defined(MS_WINDOWS)
&& defined(_DEBUG)
#if defined(MS_WINDOWS)
#define MAX_MARSHAL_STACK_DEPTH 1000
#define MAX_MARSHAL_STACK_DEPTH 1000
#else
#else
#define MAX_MARSHAL_STACK_DEPTH 2000
#define MAX_MARSHAL_STACK_DEPTH 2000
...
...
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