From ce1afad63f925694438ba1b08694673f202da693 Mon Sep 17 00:00:00 2001 From: Andreas Tsouchlos Date: Sat, 19 Apr 2025 13:40:59 +0200 Subject: [PATCH] Remove commented out code --- src/main.cpp | 51 --------------------------------------------------- 1 file changed, 51 deletions(-) diff --git a/src/main.cpp b/src/main.cpp index 26a61eb..3f027ea 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -50,54 +50,3 @@ int main() { server.disconnect(); } } - -// int main() { -// spdlog::set_level(spdlog::level::debug); -// -// tcp::NonBlockingClient client; -// -// tcp::HostString host = {"localhost"}; -// uint16_t port = 65432; -// -// spdlog::info("Connecting to {}:{}", host.data(), port); -// -// if (!client.connect(host, port)) std::terminate(); -// -// -// int status = EINPROGRESS; -// while (status == EINPROGRESS) { -// auto statusRes = client.get_last_connection_status(); -// if (!statusRes) std::terminate(); -// status = statusRes.value(); -// } -// -// char buffer[1024]; -// -// while (!client.data_available()) -// ; -// -// auto recvRes = client.recv(std::span(buffer, sizeof(buffer))); -// -// if (!recvRes) { -// std::terminate(); -// } -// -// spdlog::info("Received {} bytes", recvRes.value()); -// if (recvRes.value() > 0) { -// spdlog::info("Received message: {}", -// std::string(buffer, recvRes.value())); -// } -// -// EINPROGRESS; -// -// const char* msg = "Hello, world!"; -// auto sendRes = client.send(std::span(msg, -// strlen(msg))); if (!sendRes) { -// spdlog::error("Failed to send message"); -// std::terminate(); -// } -// spdlog::info("Sent {} bytes", sendRes.value()); -// client.disconnect(); -// -// return 0; -// }