Don't crash of a socket is closed server side
authorJesse Gumm <gumm@sigma-star.com>
Wed, 26 Sep 2018 20:19:33 +0000 (15:19 -0500)
committerJesse Gumm <gumm@sigma-star.com>
Wed, 26 Sep 2018 20:20:39 +0000 (15:20 -0500)
commit0f543eda81bf1e938365f008fda88eb695ab56ce
tree62c8f8453e1af956f691bcfe99575e9fbd92683a
parentc06e08ee29e215cc7f3e5f940fabf5f5834a7096
Don't crash of a socket is closed server side

If for some reason, the programmer decides to close the socket server side,
the return value for setopts on the socket is {error, einval} rather than
{error, closed}. This change accepts that and suppresses the error message
generated.
src/mochiweb_socket.erl