mirror of
https://github.com/yhirose/cpp-httplib.git
synced 2025-05-10 09:43:51 +00:00
Fixed warning
This commit is contained in:
parent
89440ec322
commit
6d8302313c
@ -536,7 +536,7 @@ TEST(YahooRedirectTest, Redirect) {
|
|||||||
EXPECT_EQ(200, res->status);
|
EXPECT_EQ(200, res->status);
|
||||||
}
|
}
|
||||||
|
|
||||||
TEST(Https2HttpRedirectTest, Redirect) {
|
TEST(HttpsToHttpRedirectTest, Redirect) {
|
||||||
httplib::SSLClient cli("httpbin.org");
|
httplib::SSLClient cli("httpbin.org");
|
||||||
cli.follow_location(true);
|
cli.follow_location(true);
|
||||||
auto res = cli.Get("/redirect-to?url=http%3A%2F%2Fwww.google.com&status_code=302");
|
auto res = cli.Get("/redirect-to?url=http%3A%2F%2Fwww.google.com&status_code=302");
|
||||||
@ -637,7 +637,7 @@ protected:
|
|||||||
size_t DATA_CHUNK_SIZE = 4;
|
size_t DATA_CHUNK_SIZE = 4;
|
||||||
const auto &d = *data;
|
const auto &d = *data;
|
||||||
auto out_len = std::min(static_cast<size_t>(length), DATA_CHUNK_SIZE);
|
auto out_len = std::min(static_cast<size_t>(length), DATA_CHUNK_SIZE);
|
||||||
sink(&d[offset], out_len);
|
sink(&d[static_cast<size_t>(offset)], out_len);
|
||||||
},
|
},
|
||||||
[data] { delete data; });
|
[data] { delete data; });
|
||||||
})
|
})
|
||||||
|
Loading…
x
Reference in New Issue
Block a user