mirror of
https://github.com/XRPLF/rippled.git
synced 2025-12-06 17:27:55 +00:00
Update Beast subtree to 1.0.0-b23:
Merge commit '7028579170d83cb81a97478b620f3cb15a2fd693' into develop
This commit is contained in:
@@ -8,17 +8,27 @@
|
||||
#include "websocket_async_echo_server.hpp"
|
||||
#include "websocket_sync_echo_server.hpp"
|
||||
#include <beast/test/sig_wait.hpp>
|
||||
#include <iostream>
|
||||
|
||||
int main()
|
||||
{
|
||||
using endpoint_type = boost::asio::ip::tcp::endpoint;
|
||||
using address_type = boost::asio::ip::address;
|
||||
|
||||
beast::websocket::async_echo_server s1(true, endpoint_type{
|
||||
address_type::from_string("127.0.0.1"), 6000 }, 4);
|
||||
try
|
||||
{
|
||||
boost::system::error_code ec;
|
||||
beast::websocket::async_echo_server s1{nullptr, 1};
|
||||
s1.open(true, endpoint_type{
|
||||
address_type::from_string("127.0.0.1"), 6000 }, ec);
|
||||
|
||||
beast::websocket::sync_echo_server s2(true, endpoint_type{
|
||||
address_type::from_string("127.0.0.1"), 6001 });
|
||||
beast::websocket::sync_echo_server s2(true, endpoint_type{
|
||||
address_type::from_string("127.0.0.1"), 6001 });
|
||||
|
||||
beast::test::sig_wait();
|
||||
beast::test::sig_wait();
|
||||
}
|
||||
catch(std::exception const& e)
|
||||
{
|
||||
std::cout << "Error: " << e.what() << std::endl;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user