elixir-circuits / circuits_i2c

Communicate over I2C from Elixir
Apache License 2.0
62 stars 12 forks source link

Remove deferred loading of NIF #160

Closed fhunleth closed 8 months ago

fhunleth commented 8 months ago

It was possible to crash the BEAM by loading a completely trimmed down shared library with multiple processes. This converts the NIF loader back to the traditional @on_load way that's serialized by the code loader. The benefits of delaying the load time are less now that the shared library has been tested quite a bit.