Skip to content
Snippets Groups Projects
Commit 4d152fde authored by Nicolas Werner's avatar Nicolas Werner
Browse files

Fix warning about ignored qualifiers

parent abc485a1
No related branches found
No related tags found
No related merge requests found
...@@ -41,7 +41,7 @@ using Callback = std::function<void(const Response &, RequestErr)>; ...@@ -41,7 +41,7 @@ using Callback = std::function<void(const Response &, RequestErr)>;
template<class Response> template<class Response>
using HeadersCallback = std::function<void(const Response &, HeaderFields, RequestErr)>; using HeadersCallback = std::function<void(const Response &, HeaderFields, RequestErr)>;
using TypeErasedCallback = std::function<void(const HeaderFields &, using TypeErasedCallback = std::function<void(HeaderFields,
const std::string &, const std::string &,
const boost::system::error_code &, const boost::system::error_code &,
boost::beast::http::status)>; boost::beast::http::status)>;
...@@ -457,7 +457,7 @@ template<class Response> ...@@ -457,7 +457,7 @@ template<class Response>
mtx::http::TypeErasedCallback mtx::http::TypeErasedCallback
mtx::http::Client::prepare_callback(HeadersCallback<Response> callback) mtx::http::Client::prepare_callback(HeadersCallback<Response> callback)
{ {
auto type_erased_cb = [callback](const HeaderFields &headers, auto type_erased_cb = [callback](HeaderFields headers,
const std::string &body, const std::string &body,
const boost::system::error_code &err_code, const boost::system::error_code &err_code,
boost::beast::http::status status_code) { boost::beast::http::status status_code) {
......
...@@ -55,10 +55,7 @@ Client::Client(const std::string &server, uint16_t port) ...@@ -55,10 +55,7 @@ Client::Client(const std::string &server, uint16_t port)
Client::~Client() { p.reset(); } Client::~Client() { p.reset(); }
std::shared_ptr<Session> std::shared_ptr<Session>
Client::create_session(std::function<void(const HeaderFields &, Client::create_session(TypeErasedCallback type_erased_cb)
const std::string &,
const boost::system::error_code &,
boost::beast::http::status)> type_erased_cb)
{ {
auto session = std::make_shared<Session>( auto session = std::make_shared<Session>(
std::ref(p->ios_), std::ref(p->ios_),
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment