From 79b1d156c42071a81150b5c6cd9e4582ba3111ed Mon Sep 17 00:00:00 2001 From: Scott Lystig Fritchie Date: Wed, 16 Sep 2015 13:52:36 +0900 Subject: [PATCH] Add backlog option to gen_tcp:listen --- src/machi_flu1.erl | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/machi_flu1.erl b/src/machi_flu1.erl index 1227375..e18d06c 100644 --- a/src/machi_flu1.erl +++ b/src/machi_flu1.erl @@ -189,7 +189,8 @@ start_append_server(S, AckPid) -> run_listen_server(#state{flu_name=FluName, tcp_port=TcpPort}=S) -> register(make_listener_regname(FluName), self()), SockOpts = ?PB_PACKET_OPTS ++ - [{reuseaddr, true}, {mode, binary}, {active, false}], + [{reuseaddr, true}, {mode, binary}, {active, false}, + {backlog,8192}], case gen_tcp:listen(TcpPort, SockOpts) of {ok, LSock} -> listen_server_loop(LSock, S);