diff options
author | Ingela Anderton Andin <[email protected]> | 2019-05-29 22:53:01 +0200 |
---|---|---|
committer | Ingela Anderton Andin <[email protected]> | 2019-05-31 08:00:39 +0200 |
commit | 85857a544e27cc0b9a3637af4ea2aff927ec7951 (patch) | |
tree | 8294af19e3f08ad003e70193682abe5286fd5245 /lib/ssl/src/ssl_connection.erl | |
parent | 6310fbd9871f521826d4672395e48e2ef94d59a9 (diff) | |
download | otp-85857a544e27cc0b9a3637af4ea2aff927ec7951.tar.gz otp-85857a544e27cc0b9a3637af4ea2aff927ec7951.tar.bz2 otp-85857a544e27cc0b9a3637af4ea2aff927ec7951.zip |
ssl: Fix broken return value
Diffstat (limited to 'lib/ssl/src/ssl_connection.erl')
-rw-r--r-- | lib/ssl/src/ssl_connection.erl | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/lib/ssl/src/ssl_connection.erl b/lib/ssl/src/ssl_connection.erl index 7047c01657..cc4d60389e 100644 --- a/lib/ssl/src/ssl_connection.erl +++ b/lib/ssl/src/ssl_connection.erl @@ -124,7 +124,7 @@ handshake(#sslsocket{pid = [Pid|_]} = Socket, Timeout) -> connected -> {ok, Socket}; {ok, Ext} -> - {ok, Socket, Ext}; + {ok, Socket, no_records(Ext)}; Error -> Error end. @@ -709,6 +709,7 @@ handle_session(#server_hello{cipher_suite = CipherSuite, {ExpectNPN, Protocol} = case Protocol0 of undefined -> + {false, CurrentProtocol}; _ -> {ProtoExt =:= npn, Protocol0} @@ -3000,3 +3001,8 @@ new_emulated([], EmOpts) -> EmOpts; new_emulated(NewEmOpts, _) -> NewEmOpts. + +no_records(Extensions) -> + maps:map(fun(_, Value) -> + ssl_handshake:extension_value(Value) + end, Extensions). |