From 3b43a2fa050ac1b5f86a722bc556e74f6b44a3c9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?P=C3=A9ter=20Dimitrov?= Date: Tue, 6 Feb 2018 10:17:19 +0100 Subject: inets: Fix httpc crash on keep-alive connections - Set gen_server call timeout to infinity in httpc_handler. - Add new testcase 'slow_connection'. Change-Id: Id11b54c588e1d66b9ebba4da5dbfe5e9bee1f1ee --- lib/inets/src/http_client/httpc_handler.erl | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'lib/inets/src/http_client') diff --git a/lib/inets/src/http_client/httpc_handler.erl b/lib/inets/src/http_client/httpc_handler.erl index 1482f4f922..a4e406b807 100644 --- a/lib/inets/src/http_client/httpc_handler.erl +++ b/lib/inets/src/http_client/httpc_handler.erl @@ -711,9 +711,9 @@ do_handle_info({'EXIT', _, _}, State = #state{request = undefined}) -> %% can retry requests in the pipeline. do_handle_info({'EXIT', _, _}, State) -> {noreply, State#state{status = close}}. - + call(Msg, Pid) -> - try gen_server:call(Pid, Msg) + try gen_server:call(Pid, Msg, infinity) catch exit:{noproc, _} -> {error, closed}; -- cgit v1.2.3