Skip to content

Commit

Permalink
Do not trigger SSL CLIET ALERT when shutdown
Browse files Browse the repository at this point in the history
  • Loading branch information
zmstone authored and IngelaAndin committed Oct 25, 2024
1 parent 412bff5 commit 5c25ba4
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions lib/ssl/src/ssl_gen_statem.erl
Original file line number Diff line number Diff line change
Expand Up @@ -1888,11 +1888,12 @@ log_alert(Level, Role, ProtocolName, StateName, Alert) ->
statename => StateName,
alert => Alert,
alerter => peer}, Alert#alert.where).
terminate_alert(normal) ->
?ALERT_REC(?WARNING, ?CLOSE_NOTIFY);
terminate_alert({Reason, _}) when Reason == close;
Reason == shutdown ->
terminate_alert(Reason) when Reason == normal;
Reason == shutdown;
Reason == close ->
?ALERT_REC(?WARNING, ?CLOSE_NOTIFY);
terminate_alert({Reason, _}) ->
terminate_alert(Reason);
terminate_alert(_) ->
?ALERT_REC(?FATAL, ?INTERNAL_ERROR).

Expand Down

0 comments on commit 5c25ba4

Please sign in to comment.