lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]


Hi again,

It looks like if I wan't a Lua state shared between multiple processes, I'll have to rewrite/replace Lua's memory allocation functions. Can anyone confirm for me that all I need to touch are the :

#ifndef l_realloc
#define l_realloc(b,os,s)    realloc(b,s)
#endif

and

#ifndef l_free
#define l_free(b,os)    free(b)
#endif

functions?

Also, can anyone suggest the best way to do this? Via memory-mapped files, a huge block allocated at dll initialisation or someother technique?

Thanks for any help,

George

--
George Sealy, PhD                       email : george@arl.co.nz
Software Developer / Architect          phone : +64 3 477 2995
Animation Research Ltd