mirror of
https://github.com/RIOT-OS/RIOT.git
synced 2024-12-29 04:50:03 +01:00
Merge pull request #5682 from LudwigKnuepfer/pr/fix-5680
cpu/native: fix thread_stack_init
This commit is contained in:
commit
2dcce17bca
@ -94,7 +94,7 @@ char *thread_stack_init(thread_task_func_t task_func, void *arg, void *stack_sta
|
||||
|
||||
stk = stack_start;
|
||||
|
||||
p = (ucontext_t *)(stk + ((stacksize - sizeof(ucontext_t)) / sizeof(void *)));
|
||||
p = (ucontext_t *)(stk + (stacksize - sizeof(ucontext_t)));
|
||||
stacksize -= sizeof(ucontext_t);
|
||||
|
||||
if (getcontext(p) == -1) {
|
||||
|
Loading…
Reference in New Issue
Block a user