aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--src/gun.erl4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/gun.erl b/src/gun.erl
index 7121324..38cb68a 100644
--- a/src/gun.erl
+++ b/src/gun.erl
@@ -374,9 +374,9 @@ connect(State=#state{owner=Owner, host=Host, port=Port, type=Type}, Retries) ->
retry_loop(State, Retries - 1)
end.
-%% Too many failures, give up.
+%% Too many retries, give up.
retry_loop(_, 0) ->
- error(too_many_retries);
+ error(gone);
retry_loop(State=#state{parent=Parent, retry_timeout=RetryTimeout}, Retries) ->
_ = erlang:send_after(RetryTimeout, self(), retry),
receive