diff options
| author | sommersoft <sommersoft@gmail.com> | 2020-06-20 08:41:41 -0500 |
|---|---|---|
| committer | sommersoft <sommersoft@gmail.com> | 2020-06-20 08:41:41 -0500 |
| commit | 023054e67acdd209c7990bba19b460adc4d6001e (patch) | |
| tree | b6002654bee95398f620cbdfd002d8e04c04ca7d /py/stackctrl.c | |
| parent | c7b6d35fd43ca192c3e7e95bf0a0f2ea0b0fc4a5 (diff) | |
| parent | 986664659e8408f25d3d8aa58926046cafede39f (diff) | |
Merge branch 'main' of https://github.com/adafruit/circuitpython into ci_check_vid_pid
Diffstat (limited to 'py/stackctrl.c')
| -rw-r--r-- | py/stackctrl.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/py/stackctrl.c b/py/stackctrl.c index 46cbefc8c..26fc065b7 100644 --- a/py/stackctrl.c +++ b/py/stackctrl.c @@ -77,7 +77,7 @@ void mp_stack_set_bottom(void* stack_bottom) { // // The stack_dummy approach used elsewhere in this file is not safe in // all cases. That value may be below the actual top of the stack. -static void* approx_stack_pointer(void){ +static void* approx_stack_pointer(void){ __asm volatile (""); return __builtin_frame_address(0); } @@ -90,7 +90,7 @@ void mp_stack_fill_with_sentinel(void) { // Continue until we've hit the bottom of the stack (lowest address, // logical "ceiling" of stack). char* p = (char *) approx_stack_pointer() - 1; - + while(p >= MP_STATE_THREAD(stack_bottom)) { *p-- = MP_MAX_STACK_USAGE_SENTINEL_BYTE; } |
