[erlang-questions] Any tcp related changes in R15B* that might cause this?

Anthony Molinaro <>
Wed Dec 12 19:26:32 CET 2012


Well, yes, I did see the tcp_closed message, my real question is I guess
related to your statement

"It may be that R15 is more accurate at reporting here than R14, so the older version just accepts the result blindly and then have the no change, whereas R15 actually reports the correct error."

Can anyone from OTP clarify if any work was done with regards to error
messages?  I did not find anything in the release notes which is why
I'm wondering.

I suppose I could attempt to git bisect this or something, but I'm not
sure how difficult that might be.

Thanks,

-Anthony

On Wed, Dec 12, 2012 at 05:18:57PM +0100, Jesper Louis Andersen wrote:
> 
> On Dec 6, 2012, at 8:38 PM, Anthony Molinaro <> wrote:
> 
> > 2012-12-01 00:01:33 =CRASH REPORT====
> >  crasher:
> >    initial call: mochiweb_acceptor:init/3
> >    pid: <0.2942.3599>
> >    registered_name: []
> >    exception error: {{badmatch,{error,einval}},[{mochiweb_http,new_request,3,[]},{mochiweb_http,handle_invalid_request,3,[]},{proc_lib,init_p_do_apply,3,[{file,"proc_lib.erl"},{line,227}]}]}
> >    ancestors: [webmachine_mochiweb,web_serve_sup,<0.619.0>]
> >    messages: [{tcp_closed,#Port<0.222190389>}]
> >    links: [<0.873.0>]
> >    dictionary: []
> >    trap_exit: false
> >    status: running
> >    heap_size: 987
> >    stack_size: 24
> >    reductions: 541
> >  neighbours:
> 
> If you read through the Mochi code, you will see this:
> 
> https://github.com/mochi/mochiweb/blob/master/src/mochiweb_http.erl#L125
> 
>     ok = mochiweb_socket:setopts(Socket, [{packet, raw}]),
> 
> So assuming that is true, the problem is a posix() message einval (Invalid Argument), probably because the
> socket is long dead and gone. It may be that R15 is more accurate at reporting here than R14, so the older version just accepts the result blindly and then have the no change, whereas R15 actually reports the correct error.
> 
> A thing supporting my hypothesis is that there is a tcp_closed message in your mailbox :)
> 
> 
> Jesper Louis Andersen
>   Erlang Solutions Ltd., Copenhagen
> 
> 
> 

-- 
------------------------------------------------------------------------
Anthony Molinaro                           <>



More information about the erlang-questions mailing list