Fix integer warnings in 64-bit Windows build

This commit is contained in:
Vinnie Falco
2016-08-26 07:54:20 -04:00
parent c15751ced6
commit 19dd983d2b
3 changed files with 14 additions and 11 deletions

View File

@@ -15,6 +15,7 @@
#include <beast/core/placeholders.hpp>
#include <beast/core/streambuf.hpp>
#include <boost/asio.hpp>
#include <cstddef>
#include <cstdio>
#include <iostream>
#include <memory>
@@ -44,7 +45,7 @@ class http_async_server
public:
http_async_server(endpoint_type const& ep,
int threads, std::string const& root)
std::size_t threads, std::string const& root)
: acceptor_(ios_)
, sock_(ios_)
, root_(root)
@@ -57,7 +58,7 @@ public:
std::bind(&http_async_server::on_accept, this,
beast::asio::placeholders::error));
thread_.reserve(threads);
for(int i = 0; i < threads; ++i)
for(std::size_t i = 0; i < threads; ++i)
thread_.emplace_back(
[&] { ios_.run(); });
}