From 312f0194e09a2f2cef5af3750fd750a1d0137945 Mon Sep 17 00:00:00 2001 From: Jack Lloyd Date: Mon, 7 May 2018 13:39:01 -0400 Subject: Fix some warnings new in GCC 8.1 It thinks the typedefs are "locals" that are being conflicted with, which seems wrong to me but whatever. --- src/lib/tls/tls_callbacks.h | 33 ++++++++++++++++++--------------- 1 file changed, 18 insertions(+), 15 deletions(-) (limited to 'src/lib/tls/tls_callbacks.h') diff --git a/src/lib/tls/tls_callbacks.h b/src/lib/tls/tls_callbacks.h index 88e502e89..1e0aca9a9 100644 --- a/src/lib/tls/tls_callbacks.h +++ b/src/lib/tls/tls_callbacks.h @@ -353,40 +353,43 @@ class BOTAN_PUBLIC_API(2,0) Compat_Callbacks final : public Callbacks * @param next_proto is called with ALPN protocol data sent by the client */ BOTAN_DEPRECATED("Use TLS::Callbacks (virtual interface).") - Compat_Callbacks(output_fn output_fn, data_cb app_data_cb, alert_cb alert_cb, + Compat_Callbacks(output_fn data_output_fn, data_cb app_data_cb, alert_cb recv_alert_cb, handshake_cb hs_cb, handshake_msg_cb hs_msg_cb = nullptr, next_protocol_fn next_proto = nullptr) - : m_output_function(output_fn), m_app_data_cb(app_data_cb), - m_alert_cb(std::bind(alert_cb, std::placeholders::_1, nullptr, 0)), + : m_output_function(data_output_fn), m_app_data_cb(app_data_cb), + m_alert_cb(std::bind(recv_alert_cb, std::placeholders::_1, nullptr, 0)), m_hs_cb(hs_cb), m_hs_msg_cb(hs_msg_cb), m_next_proto(next_proto) {} BOTAN_DEPRECATED("Use TLS::Callbacks (virtual interface).") - Compat_Callbacks(output_fn output_fn, data_cb app_data_cb, - std::function alert_cb, + Compat_Callbacks(output_fn data_output_fn, data_cb app_data_cb, + std::function recv_alert_cb, handshake_cb hs_cb, handshake_msg_cb hs_msg_cb = nullptr, next_protocol_fn next_proto = nullptr) - : m_output_function(output_fn), m_app_data_cb(app_data_cb), - m_alert_cb(alert_cb), + : m_output_function(data_output_fn), m_app_data_cb(app_data_cb), + m_alert_cb(recv_alert_cb), m_hs_cb(hs_cb), m_hs_msg_cb(hs_msg_cb), m_next_proto(next_proto) {} enum class SILENCE_DEPRECATION_WARNING { PLEASE = 0 }; Compat_Callbacks(SILENCE_DEPRECATION_WARNING, - output_fn output_fn, data_cb app_data_cb, - std::function alert_cb, + output_fn data_output_fn, data_cb app_data_cb, + std::function recv_alert_cb, handshake_cb hs_cb, handshake_msg_cb hs_msg_cb = nullptr, next_protocol_fn next_proto = nullptr) - : m_output_function(output_fn), m_app_data_cb(app_data_cb), - m_alert_cb(alert_cb), - m_hs_cb(hs_cb), m_hs_msg_cb(hs_msg_cb), m_next_proto(next_proto) {} + : m_output_function(data_output_fn), + m_app_data_cb(app_data_cb), + m_alert_cb(recv_alert_cb), + m_hs_cb(hs_cb), + m_hs_msg_cb(hs_msg_cb), + m_next_proto(next_proto) {} Compat_Callbacks(SILENCE_DEPRECATION_WARNING, - output_fn output_fn, data_cb app_data_cb, alert_cb alert_cb, + output_fn data_output_fn, data_cb app_data_cb, alert_cb recv_alert_cb, handshake_cb hs_cb, handshake_msg_cb hs_msg_cb = nullptr, next_protocol_fn next_proto = nullptr) - : m_output_function(output_fn), m_app_data_cb(app_data_cb), - m_alert_cb(std::bind(alert_cb, std::placeholders::_1, nullptr, 0)), + : m_output_function(data_output_fn), m_app_data_cb(app_data_cb), + m_alert_cb(std::bind(recv_alert_cb, std::placeholders::_1, nullptr, 0)), m_hs_cb(hs_cb), m_hs_msg_cb(hs_msg_cb), m_next_proto(next_proto) {} -- cgit v1.2.3