aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--src/ranch_ssl.erl1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/ranch_ssl.erl b/src/ranch_ssl.erl
index 59e842c..53bcf8a 100644
--- a/src/ranch_ssl.erl
+++ b/src/ranch_ssl.erl
@@ -275,6 +275,7 @@ ssl_accept(Socket, Timeout) ->
ok ->
{ok, Socket};
{error, Reason} ->
+ ok = close(Socket),
{error, {ssl_accept, Reason}}
end.