Unverified Commit 9c6f5d1c authored by miketsts's avatar miketsts Committed by GitHub

Fix -wConversion warnings #748 (#754)

* Fix -wConversion warning in async.h #748

Fix a warning about problematic conversion from 'long int' to 'int'
appearing when compiling http.cc with -wConversion flag

* Suppress -wConversion warnings in date.h #748

Suppress warnings originating in date.h. The similar suppression appears
in the newer version of date.h appearing in its original repository
https://github.com/HowardHinnant/dateCo-authored-by: default avatarMichael Tseitlin <michael.tseitlin@concertio.com>
parent a328d724
......@@ -794,7 +794,7 @@ Async::Promise<ssize_t> ResponseWriter::putOnWire(const char *data,
auto fd = peer()->fd();
return transport_->asyncWrite(fd, buffer)
.then<std::function<Async::Promise<ssize_t>(int)>,
.then<std::function<Async::Promise<ssize_t>(ssize_t)>,
std::function<void(std::exception_ptr &)>>(
[=](int /*l*/) {
return Async::Promise<ssize_t>([=](
......
......@@ -8,7 +8,14 @@
#include <iostream>
#include <pistache/common.h>
#ifdef __GNUC__
#pragma GCC diagnostic push
#pragma GCC diagnostic ignored "-Wconversion"
#endif
#include <pistache/date.h>
#ifdef __GNUC__
#pragma GCC diagnostic pop
#endif
#include <pistache/http_defs.h>
namespace Pistache {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment