1 Star 1 Fork 0

zhangjiatong / JTHTTPServer

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
克隆/下载
main.cc 463 Bytes
一键复制 编辑 原始数据 按行查看 历史
zhangjiatong 提交于 2023-02-16 12:24 . 上传JThttpServer工程
#include <iostream>
#include <string>
#include <memory>
#include "HttpServer.hpp"
static void Usage(std::string proc)
{
std::cout << "Usage:\n\t" << proc << " port" << std::endl;;
}
int main(int argc, char *argv[])
{
if( argc != 2 ){
Usage(argv[0]);
exit(4);
}
int port = atoi(argv[1]);
std::shared_ptr<HttpServer> http_server(new HttpServer(port));
http_server->InitServer();
http_server->Loop();
return 0;
}
C++
1
https://gitee.com/zhangjiatong/jthttpserver.git
git@gitee.com:zhangjiatong/jthttpserver.git
zhangjiatong
jthttpserver
JTHTTPServer
master

搜索帮助