Fix for a race condition in percept

Ahmed Omar <>
Wed Dec 15 11:36:27 CET 2010

Fixes a race condition found in percept_db start/1 function.

When function start/1 finds an instance of percept_db running, it will
send a message to stop it and spawn a process to start a new one,
which leads to a race condition.
The function will return {restarted, pid()} but the pid() will die
once it tries to create the ets table.

git fetch git:// percept_race_cond

Best Regards,
- Ahmed Omar
Follow me on twitter
@spawn_think <!/spawn_think>

More information about the erlang-patches mailing list