Skip to content

Commit 7b432e3

Browse files
committed
Don't set the stack pointer to NULL on release builds
1 parent a123245 commit 7b432e3

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

Include/internal/pycore_interpframe.h

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -171,7 +171,9 @@ _PyFrame_GetStackPointer(_PyInterpreterFrame *frame)
171171
{
172172
assert(frame->stackpointer != NULL);
173173
_PyStackRef *sp = frame->stackpointer;
174+
#ifndef NDEBUG
174175
frame->stackpointer = NULL;
176+
#endif
175177
return sp;
176178
}
177179

0 commit comments

Comments
 (0)