Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
So turns out the "Fix for mochiweb_acceptor crash under R15B02" from
#91 was a bug in OTP fixed in R16B.
erlang/otp@6aa9e71
So it worked in R14, was broken in R15 and got fixed in R16. This commit
makes it such that things will work as well as possible in each version.
In rebar.config I set a compiler option if on R14 or R16, in mochiweb_http.erl
I make the extra R15 clause be added with the macro, then in
mochiweb_socket_server.erl I add in { exit_on_close, false } to the options.
In addition there is a script which will detect if the fix is needed based
on my test case from issue 91.
Just run 'make ; cd scripts ; ./check_for_gen_tcp_fix.erl' and it should
return true if the fix is in place.