Skip to content

Commit 1909ad3

Browse files
committed
---
yaml --- r: 6768 b: refs/heads/master c: 23df4de h: refs/heads/master v: v3
1 parent 869bcb2 commit 1909ad3

File tree

2 files changed

+3
-5
lines changed

2 files changed

+3
-5
lines changed

[refs]

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
11
---
2-
refs/heads/master: ab4f35c1f1247bd745378621a22340cbf8b7030d
2+
refs/heads/master: 23df4de86d8740545891a745f3c2f6c90cf1d1fd

trunk/src/rt/rust_task.cpp

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -596,10 +596,8 @@ rust_task::new_stack(size_t stk_sz, void *args_addr, size_t args_sz) {
596596
stk_seg *stk_seg = new_stk(sched, this, stk_sz + args_sz);
597597

598598
uint8_t *new_sp = (uint8_t*)stk_seg->end;
599-
size_t sizeof_retaddr = sizeof(void*);
600-
// Make enough room on the new stack to hold the old stack pointer
601-
// in addition to the function arguments
602-
new_sp = align_down(new_sp - (args_sz + sizeof_retaddr));
599+
// Push the function arguments to the new stack
600+
new_sp = align_down(new_sp - args_sz);
603601
memcpy(new_sp, args_addr, args_sz);
604602
record_stack_limit();
605603
return new_sp;

0 commit comments

Comments
 (0)