mirror of
https://github.com/yhirose/cpp-httplib.git
synced 2026-01-19 04:52:08 +00:00
Fix warning on Windows
This commit is contained in:
10
test/test.cc
10
test/test.cc
@@ -10709,7 +10709,15 @@ TEST(VulnerabilityTest, CRLFInjectionInHeaders) {
|
||||
}
|
||||
|
||||
std::string resp = "HTTP/1.1 200 OK\r\nContent-Length: 5\r\n\r\nHello";
|
||||
::send(cli, resp.c_str(), resp.size(), 0);
|
||||
|
||||
::send(cli,
|
||||
#ifdef _WIN32
|
||||
static_cast<const char *>(resp.c_str()),
|
||||
static_cast<int>(resp.size()),
|
||||
#else
|
||||
resp.c_str(), resp.size(),
|
||||
#endif
|
||||
0);
|
||||
|
||||
buf_all.erase(0, pos + 4);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user