Skip to content

Commit

Permalink
Fix possible 32bit integer overflow of offset in bigarray C implement…
Browse files Browse the repository at this point in the history
…ation.
  • Loading branch information
Nevor committed Mar 16, 2022
1 parent 1447446 commit 978bebe
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion runtime/bigarray.c
Expand Up @@ -524,7 +524,7 @@ CAMLprim value caml_ba_create(value vkind, value vlayout, value vdim)
are within the bounds and return the offset of the corresponding
array element in the data part of the array. */

static long caml_ba_offset(struct caml_ba_array * b, intnat * index)
static intnat caml_ba_offset(struct caml_ba_array * b, intnat * index)
{
intnat offset;
int i;
Expand Down

0 comments on commit 978bebe

Please sign in to comment.