Skip to content

Commit e9b3f74

Browse files
committed
Fix another stack assert on HP-PA (pythonGH-140028)
Missed in pythonGH-139914, as it was introduced around the same time and is only relevant to pydebug builds.
1 parent 52f9b5f commit e9b3f74

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

Python/ceval.c

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -514,7 +514,11 @@ tstate_set_stack(PyThreadState *tstate,
514514
uintptr_t base, uintptr_t top)
515515
{
516516
assert(base < top);
517+
#if _Py_STACK_GROWS_DOWN
517518
assert((top - base) >= _PyOS_MIN_STACK_SIZE);
519+
#else
520+
assert((base - top) >= _PyOS_MIN_STACK_SIZE);
521+
#endif
518522

519523
#ifdef _Py_THREAD_SANITIZER
520524
// Thread sanitizer crashes if we use more than half the stack.

0 commit comments

Comments
 (0)