Proteger contre des appels multiples a init_toplevel, ce qui peut arriver si Dynlink.init est appele plusieurs fois (PR#1602)
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@5581 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02master
parent
7eeb3bb5c4
commit
8bfcd7d608
|
@ -255,6 +255,7 @@ let init_toplevel () =
|
|||
ignore(Bytesections.seek_section ic "SYMB");
|
||||
global_table := (input_value ic : Ident.t numtable);
|
||||
let prims = Bytesections.read_section ic "PRIM" in
|
||||
c_prim_table := empty_numtable;
|
||||
let pos = ref 0 in
|
||||
while !pos < String.length prims do
|
||||
let i = String.index_from prims !pos '\000' in
|
||||
|
|
Loading…
Reference in New Issue