switch back to boost::filesystem to avoid the requirement of c++17

This commit is contained in:
Chunting Gu
2020-09-07 19:01:31 +08:00
parent e7f88da2b2
commit 84476f75f7
31 changed files with 175 additions and 192 deletions
+4 -3
View File
@@ -1,11 +1,12 @@
#ifndef WEBCC_SERVER_H_
#define WEBCC_SERVER_H_
#include <filesystem>
#include <string>
#include <thread>
#include <vector>
#include "boost/filesystem/path.hpp"
#include "boost/asio/io_context.hpp"
#include "boost/asio/ip/tcp.hpp"
#include "boost/asio/signal_set.hpp"
@@ -21,7 +22,7 @@ namespace webcc {
class Server : public Router {
public:
Server(boost::asio::ip::tcp protocol, std::uint16_t port,
const std::filesystem::path& doc_root = {});
const boost::filesystem::path& doc_root = {});
~Server() = default;
@@ -101,7 +102,7 @@ private:
std::uint16_t port_;
// The directory with the static files to be served.
std::filesystem::path doc_root_;
boost::filesystem::path doc_root_;
// The size of the chunk loaded into memory each time when serving a
// static file.