| 5 | const uint32_t Socket::MTU = 1024; |
| 6 | |
| 7 | Socket::Socket(const std::string& ip, uint16_t port) |
| 8 | : endpoint(asio::ip::address::from_string(ip), port), socket(io_context) { |
| 9 | try { |
| 10 | socket.connect(endpoint); |
| 11 | } catch (const std::exception& e) { |
| 12 | std::cerr << "Error connecting to endpoint: " << e.what() << std::endl; |
| 13 | throw; |
| 14 | } |
| 15 | } |
| 16 | |
| 17 | Socket::~Socket() |
| 18 | { |
nothing calls this directly
no outgoing calls
no test coverage detected