linux changes
This commit is contained in:
1 parent
22ee99418d
commit
bd17d0ff9e
3 files changed
+12
-12
No files matched your search
@@ -45,4 +45,4 @@ if(WIN32)
|
||||
endif()
|
||||
|
||||
# Дополнительный макрос, чтобы Asio знал, что мы работаем без устаревших функций
|
||||
target_compile_definitions(Server PRIVATE BOOST_ASIO_NO_DEPRECATED)
|
||||
target_compile_definitions(Server PRIVATE BOOST_ASIO_NO_DEPRECATED)
|
||||
+3
-3
@@ -669,11 +669,11 @@ int main() {
|
||||
std::cout << "Generated " << g_serverBoxes.size() << " boxes on server\n";
|
||||
}
|
||||
net::io_context ioc;
|
||||
tcp::acceptor acceptor{ ioc, {tcp::v4(), 8081} };
|
||||
tcp::acceptor acceptor{ ioc, {tcp::v4(), 8010} };
|
||||
|
||||
int next_id = 1000;
|
||||
|
||||
std::cout << "Server started on port 8081...\n";
|
||||
std::cout << "Server started on port 8010...\n";
|
||||
|
||||
auto do_accept = [&](auto& self_fn) -> void {
|
||||
acceptor.async_accept([&, self_fn](beast::error_code ec, tcp::socket socket) {
|
||||
@@ -694,4 +694,4 @@ int main() {
|
||||
std::cerr << "Error: " << e.what() << std::endl;
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user