aboutsummaryrefslogtreecommitdiffstats
path: root/lib/inets/src
diff options
context:
space:
mode:
authorLuca Favatella <[email protected]>2018-03-16 21:03:19 +0000
committerLuca Favatella <[email protected]>2018-03-23 17:00:42 +0000
commit2591eddc8db45c89e01ceefa009537aaf660ac82 (patch)
treeafb2823b83dec78dbc060185cc7f349a0ab8a6b0 /lib/inets/src
parentb9a2da76f0a4d84b749c4ac6ef8d269994385593 (diff)
downloadotp-2591eddc8db45c89e01ceefa009537aaf660ac82.tar.gz
otp-2591eddc8db45c89e01ceefa009537aaf660ac82.tar.bz2
otp-2591eddc8db45c89e01ceefa009537aaf660ac82.zip
inets: Remove httpc dead code re init error
... i.e. references to `connect_failed` and `send_failed`, unused since 5d32eaf750 .
Diffstat (limited to 'lib/inets/src')
-rw-r--r--lib/inets/src/http_client/httpc_handler.erl21
1 files changed, 1 insertions, 20 deletions
diff --git a/lib/inets/src/http_client/httpc_handler.erl b/lib/inets/src/http_client/httpc_handler.erl
index 9b09832eb8..327aec4baa 100644
--- a/lib/inets/src/http_client/httpc_handler.erl
+++ b/lib/inets/src/http_client/httpc_handler.erl
@@ -48,12 +48,10 @@
queue_timer :: reference() | 'undefined'
}).
--type session_failed() :: {'connect_failed',term()} | {'send_failed',term()}.
-
-record(state,
{
request :: request() | 'undefined',
- session :: session() | session_failed() | 'undefined',
+ session :: session() | 'undefined',
status_line, % {Version, StatusCode, ReasonPharse}
headers :: http_response_h() | 'undefined',
body :: binary() | 'undefined',
@@ -295,23 +293,6 @@ handle_info(Info, State) ->
%% Description: Shutdown the httpc_handler
%%--------------------------------------------------------------------
-%% Init error there is no socket to be closed.
-terminate(normal,
- #state{request = Request,
- session = {send_failed, _} = Reason} = State) ->
- maybe_send_answer(Request,
- httpc_response:error(Request, Reason),
- State),
- ok;
-
-terminate(normal,
- #state{request = Request,
- session = {connect_failed, _} = Reason} = State) ->
- maybe_send_answer(Request,
- httpc_response:error(Request, Reason),
- State),
- ok;
-
terminate(normal, #state{session = undefined}) ->
ok;