Skip to content

Commit aba525d

Browse files
author
King_DuckZ
committed
Warning fix on gcc 9.3.0 with logging disabled
1 parent 48bc608 commit aba525d

File tree

2 files changed

+4
-8
lines changed

2 files changed

+4
-8
lines changed

include/restc-cpp/restc-cpp.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -145,7 +145,7 @@ class Request {
145145
class Properties {
146146
public:
147147
using ptr_t = std::shared_ptr<Properties>;
148-
using redirect_fn_t = std::function<void (int code, std::string& url,
148+
using redirect_fn_t = std::function<void (int code, std::string& url,
149149
const Reply& reply)>;
150150

151151
int maxRedirects = 3;
@@ -382,7 +382,7 @@ class RestClient {
382382
done_handler.reset();
383383
});
384384

385-
return move(future);
385+
return future;
386386
}
387387

388388

src/IoWriterImpl.cpp

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -33,9 +33,7 @@ class IoWriterImpl : public DataWriter {
3333
connection_->GetSocket().AsyncWrite(buffers, ctx_.GetYield());
3434
}
3535

36-
const auto bytes = boost::asio::buffer_size(buffers);
37-
38-
RESTC_CPP_LOG_TRACE_("Wrote #" << bytes
36+
RESTC_CPP_LOG_TRACE_("Wrote #" << boost::asio::buffer_size(buffers)
3937
<< " bytes to " << connection_);
4038
}
4139

@@ -49,9 +47,7 @@ class IoWriterImpl : public DataWriter {
4947
connection_->GetSocket().AsyncWrite(buffers, ctx_.GetYield());
5048
}
5149

52-
const auto bytes = boost::asio::buffer_size(buffers);
53-
54-
RESTC_CPP_LOG_TRACE_("Wrote #" << bytes
50+
RESTC_CPP_LOG_TRACE_("Wrote #" << boost::asio::buffer_size(buffers)
5551
<< " bytes to " << connection_);
5652
}
5753

0 commit comments

Comments
 (0)