Skip to content

Commit 0a4bfb6

Browse files
Aiden Fox Iveyk0kubun
authored andcommitted
ZJIT: Add correction rb_zjit_exit_locations_dict
1 parent 0f3d3c7 commit 0a4bfb6

1 file changed

Lines changed: 3 additions & 2 deletions

File tree

zjit.c

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -93,8 +93,9 @@ rb_zjit_exit_locations_dict(VALUE *zjit_raw_samples, int *zjit_line_samples, int
9393
int line_num = (int)zjit_line_samples[idx];
9494
idx++;
9595

96-
rb_ary_push(raw_samples, SIZET2NUM(num));
97-
rb_ary_push(line_samples, INT2NUM(line_num));
96+
// + 1 as we append an additional sample for the insn
97+
rb_ary_push(raw_samples, SIZET2NUM(num + 1));
98+
rb_ary_push(line_samples, INT2NUM(line_num + 1));
9899

99100
// Loop through the length of samples_len and add data to the
100101
// frames hash. Also push the current value onto the raw_samples

0 commit comments

Comments
 (0)