Skip to content

Commit

Permalink
Fix possible out-of-bounds access
Browse files Browse the repository at this point in the history
  • Loading branch information
fatteneder committed May 11, 2024
1 parent 90e638f commit b1b2857
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/interpreter.c
Original file line number Diff line number Diff line change
Expand Up @@ -139,7 +139,7 @@ static jl_value_t *do_invoke(jl_value_t **args, size_t nargs, interpreter_state
argv[i-1] = eval_value(args[i], s);
jl_method_instance_t *meth = (jl_method_instance_t*)args[0];
assert(jl_is_method_instance(meth));
jl_value_t *result = jl_invoke(argv[0], &argv[1], nargs - 2, meth);
jl_value_t *result = jl_invoke(argv[0], nargs == 2 ? NULL : &argv[1], nargs - 2, meth);
JL_GC_POP();
return result;
}
Expand Down

0 comments on commit b1b2857

Please sign in to comment.