Re:Mike Pall

  • From: luozhaotian <luozhaotian@xxxxxxx>
  • To: luajit@xxxxxxxxxxxxx
  • Date: Sat, 4 Dec 2021 10:33:16 +0800 (CST)

Thanks. I ever think ffi.C.malloc is same as C malloc. So Never mix use 
ffi.C.malloc & C free or C malloc & ffi.C.free.

At 2021-12-03 23:50:00, "Mike Pall" wrote:

That's a common problem on Windows: you're mixing two different
memory allocators in one program.

The FFI dynamically loads whatever functions are named 'malloc'
and 'free' from the global namespace (ffi.C). But your C/C++
program may compile and link against completely different
functions. This is up to the toolchain and its settings.

--Mike

Other related posts:

  • » Re:Mike Pall - luozhaotian