segfault in Array.append in rare case
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@13113 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02master
parent
c8273a179c
commit
19e086795e
|
@ -319,11 +319,12 @@ static value caml_array_gather(intnat num_arrays,
|
|||
count--, src++, pos++) {
|
||||
caml_initialize(&Field(res, pos), *src);
|
||||
}
|
||||
/* Many caml_initialize in a row can create a lot of old-to-young
|
||||
refs. Give the minor GC a chance to run if it needs to. */
|
||||
res = caml_check_urgent_gc(res);
|
||||
}
|
||||
Assert(pos == size);
|
||||
|
||||
/* Many caml_initialize in a row can create a lot of old-to-young
|
||||
refs. Give the minor GC a chance to run if it needs to. */
|
||||
res = caml_check_urgent_gc(res);
|
||||
}
|
||||
CAMLreturn (res);
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue