Bug introduced in R15B01 gen_server.erl?

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

Bug introduced in R15B01 gen_server.erl?

Samuel Elliott
Hi All,

After upgrading to R15B01, one of my gen_servers began crashing during
start up with {error, timeout_value}. The server is started via
gen_server:enter_loop and is globally registerd using a name of this form
{global, server_name}.

The reason seems to be these lines in gen_server.erl, which look like a
cut-and-paste error:

enter_loop(Mod, Options, State, ServerName = {Scope, _})
  when Scope == local; Scope == local ->
    enter_loop(Mod, Options, State, ServerName, infinity);

Should one of the guards be testing for global?

(I assume enter_loop isn't heavily used!)

Cheers,
Sam.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://erlang.org/pipermail/erlang-questions/attachments/20120702/8df7f03e/attachment.html>

Reply | Threaded
Open this post in threaded view
|

Bug introduced in R15B01 gen_server.erl?

Gustav Simonsson-4

Hi Sam,

This is indeed a bug.
We will create an internal patch for this.

Thank you for reporting it!

Regards,
Gustav Simonsson
Erlang/OTP team

On 2012-07-02 04:06, Sam Bobroff wrote:

> Hi All,
>
> After upgrading to R15B01, one of my gen_servers began crashing during
> start up with {error, timeout_value}. The server is started via
> gen_server:enter_loop and is globally registerd using a name of this
> form {global, server_name}.
>
> The reason seems to be these lines in gen_server.erl, which look like
> a cut-and-paste error:
>
> enter_loop(Mod, Options, State, ServerName = {Scope, _})
>   when Scope == local; Scope == local ->
>     enter_loop(Mod, Options, State, ServerName, infinity);
>
> Should one of the guards be testing for global?
>
> (I assume enter_loop isn't heavily used!)
>
> Cheers,
> Sam.
>
>
> _______________________________________________
> erlang-questions mailing list
> erlang-questions
> http://erlang.org/mailman/listinfo/erlang-questions

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://erlang.org/pipermail/erlang-questions/attachments/20120702/657537d9/attachment.html>