~ chicken-core (chicken-5) af172af5ef25e1a7439ccf9650c5de65337b5ceb
commit af172af5ef25e1a7439ccf9650c5de65337b5ceb
Author: Peter Bex <peter@more-magic.net>
AuthorDate: Sat Aug 22 18:12:56 2015 +0200
Commit: Peter Bex <peter@more-magic.net>
CommitDate: Sat Aug 22 19:37:26 2015 +0200
fixedx off-by-one in C_context_switch
diff --git a/runtime.c b/runtime.c
index d5f84626..c2db4815 100644
--- a/runtime.c
+++ b/runtime.c
@@ -11487,13 +11487,12 @@ void C_ccall C_context_switch(C_word c, C_word *av)
{
C_word
/* closure = av[ 0 ] */
- k = av[ 1 ],
state = av[ 2 ],
n = C_header_size(state) - 1,
adrs = C_block_item(state, 0);
C_proc tp = (C_proc)C_block_item(adrs,0);
- tp(n, (C_word *)state + 1);
+ tp(n, (C_word *)state + 2);
}
Trap