#22734 marshal needs a lower stack depth for debug builds on Windows

This commit is contained in:
Steve Dower 2014-11-01 15:15:16 -07:00
parent 53683965aa
commit f6c69e6cc9
2 changed files with 2 additions and 2 deletions

View File

@ -188,7 +188,7 @@ class BugsTestCase(unittest.TestCase):
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'): if os.name == 'nt' and hasattr(sys, 'gettotalrefcount'):
MAX_MARSHAL_STACK_DEPTH = 1500 MAX_MARSHAL_STACK_DEPTH = 1000
else: else:
MAX_MARSHAL_STACK_DEPTH = 2000 MAX_MARSHAL_STACK_DEPTH = 2000
for i in range(MAX_MARSHAL_STACK_DEPTH - 2): for i in range(MAX_MARSHAL_STACK_DEPTH - 2):

View File

@ -19,7 +19,7 @@
* On Windows debug builds, reduce this value. * On Windows debug builds, reduce this value.
*/ */
#if defined(MS_WINDOWS) && defined(_DEBUG) #if defined(MS_WINDOWS) && defined(_DEBUG)
#define MAX_MARSHAL_STACK_DEPTH 1500 #define MAX_MARSHAL_STACK_DEPTH 1000
#else #else
#define MAX_MARSHAL_STACK_DEPTH 2000 #define MAX_MARSHAL_STACK_DEPTH 2000
#endif #endif