diff options
author | Loïc Hoguin <[email protected]> | 2023-04-12 10:55:23 +0200 |
---|---|---|
committer | Loïc Hoguin <[email protected]> | 2023-04-12 10:55:23 +0200 |
commit | 706594d9c80bc06a2681d2319ab7196478eb7bc4 (patch) | |
tree | d259e788781a58b663b6d5207025a958941c0b8f /src/ranch_proxy_header.erl | |
parent | e94363651aed4867c3779a72a234d4df7b2d4a6a (diff) | |
download | ranch-706594d9c80bc06a2681d2319ab7196478eb7bc4.tar.gz ranch-706594d9c80bc06a2681d2319ab7196478eb7bc4.tar.bz2 ranch-706594d9c80bc06a2681d2319ab7196478eb7bc4.zip |
Fix Dialyzer warnings for OTP-26+
Diffstat (limited to 'src/ranch_proxy_header.erl')
-rw-r--r-- | src/ranch_proxy_header.erl | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/src/ranch_proxy_header.erl b/src/ranch_proxy_header.erl index 8f73dba..254a969 100644 --- a/src/ranch_proxy_header.erl +++ b/src/ranch_proxy_header.erl @@ -886,7 +886,15 @@ v2_padding_test() -> %% this only ends up returning the keys protocol, selected_cipher_suite %% and sni_hostname *at most*. --spec to_connection_info(proxy_info()) -> ssl:connection_info(). +%% The type ssl:connection_info/0 is not exported. We just +%% replicate the relevant info tuples here. +-type ssl_connection_info() :: [ + {sni_hostname, term()} | + {selected_cipher_suite, ssl:erl_cipher_suite()} | + {protocol, ssl:protocol_version()} +]. + +-spec to_connection_info(proxy_info()) -> ssl_connection_info(). to_connection_info(ProxyInfo=#{ssl := SSL}) -> ConnInfo0 = case ProxyInfo of #{authority := Authority} -> |