Fixed bug to make trhreading work again on alpine linux. (0.41.1)
This commit is contained in:
parent
43ce9f83af
commit
c7438ca109
3 changed files with 9 additions and 4 deletions
|
|
@ -96,7 +96,8 @@ static fun_thread_ret_t fun_thread_main(void *param)
|
|||
|
||||
/* Build wrapper: LOAD_CONST <fn>; LOAD_CONST <arg0> ...; CALL argc; HALT */
|
||||
Bytecode *wrap = bytecode_new();
|
||||
int cFn = bytecode_add_constant(wrap, copy_value(&(Value){.type = VAL_FUNCTION, .fn = task->fn}));
|
||||
/* Use make_function constructor which correctly handles the pointer */
|
||||
int cFn = bytecode_add_constant(wrap, make_function(task->fn));
|
||||
bytecode_add_instruction(wrap, OP_LOAD_CONST, cFn);
|
||||
for (int i = 0; i < task->argc; ++i) {
|
||||
int cArg = bytecode_add_constant(wrap, deep_copy_value(&task->args[i]));
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue