diff options
Diffstat (limited to 'src/lib/tls/tls_channel.cpp')
-rw-r--r-- | src/lib/tls/tls_channel.cpp | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/src/lib/tls/tls_channel.cpp b/src/lib/tls/tls_channel.cpp index cfaeefeb8..4549470e2 100644 --- a/src/lib/tls/tls_channel.cpp +++ b/src/lib/tls/tls_channel.cpp @@ -122,7 +122,7 @@ Handshake_State& Channel::create_handshake_state(Protocol_Version version) io.reset(new Datagram_Handshake_IO( std::bind(&Channel::send_record_under_epoch, this, _1, _2, _3), sequence_numbers(), - m_policy.dtls_default_mtu(), + static_cast<u16bit>(m_policy.dtls_default_mtu()), m_policy.dtls_initial_timeout(), m_policy.dtls_maximum_timeout())); } @@ -632,8 +632,8 @@ SymmetricKey Channel::key_material_export(const std::string& label, size_t context_size = context.length(); if(context_size > 0xFFFF) throw Exception("key_material_export context is too long"); - salt.push_back(get_byte<u16bit>(0, context_size)); - salt.push_back(get_byte<u16bit>(1, context_size)); + salt.push_back(get_byte(0, static_cast<u16bit>(context_size))); + salt.push_back(get_byte(1, static_cast<u16bit>(context_size))); salt += to_byte_vector(context); } @@ -646,4 +646,3 @@ SymmetricKey Channel::key_material_export(const std::string& label, } } - |