driver_alloc

Alexey Romanov <>
Fri Dec 3 08:04:04 CET 2010


"Erlang and OTP in Action" says:

> One thing needs to change, now that your code will be running in the memory space
of the Erlang VM: you should no longer use the standard library
functions malloc and
free in C to manage memory. When writing a linked-in driver, you should use the
erl_driver library functions driver_alloc() and driver_free() instead.

If that's correct, shouldn't it be documented in
http://www.erlang.org/doc/tutorial/c_portdriver.html (the example
there does use driver_alloc(), but nothing is said about it in the
text), the header of http://www.erlang.org/doc/man/erl_driver.html,
etc.?

Yours, Alexey Romanov


More information about the erlang-questions mailing list