[erlang-bugs] port_info crashes when called concurrently by two processes
Anthony Ramine
n.oxyde@REDACTED
Thu Mar 12 16:05:20 CET 2015
Le 12 mars 2015 à 16:00, Anthony Ramine <n.oxyde@REDACTED> a écrit :
> Le 11 mars 2015 à 19:12, Heinz Nikolaus Gies <heinz@REDACTED> a écrit :
>
>> Adding more information,
>> this is related to SMP, if starting the erlang VM with -smp disable it does not crash.
>
> Looked at it, the code uses static variables and that looks quite wrong.
>
> https://github.com/erlang/otp/blob/36576d7de20e4e8cb7b3943cfe1b7e272b5e3971/erts/emulator/beam/io.c#L4484-4485
Removing static makes your test case not crash.
I made a pull request:
https://github.com/erlang/otp/pull/643
More information about the erlang-bugs
mailing list