Closed Nevor closed 9 years ago
The previous version of the code was using the Field macro after an allocation (caml_copy_string), in case of a bad timing, this could lead to a hard to debug memory corruption.
Field
caml_copy_string
Thanks, well spotted!
I've also simplified the function to use the Store_field macro everywhere instead of using caml_modify + Field (same thing).
Store_field
caml_modify
The new distribution is online.
The previous version of the code was using the
Field
macro after an allocation (caml_copy_string
), in case of a bad timing, this could lead to a hard to debug memory corruption.