diff --git a/tlib/include/tlib/net.hpp b/tlib/include/tlib/net.hpp index 6d486e93..728c8151 100644 --- a/tlib/include/tlib/net.hpp +++ b/tlib/include/tlib/net.hpp @@ -119,7 +119,6 @@ private: socket_protocol protocol; ///< The socket protocol size_t fd; ///< The socket file descriptor size_t error_code; ///< The error code - size_t local_port; ///< The local port bool _connected; ///< Connection flag bool _bound; ///< Bind flag }; diff --git a/tlib/src/net.cpp b/tlib/src/net.cpp index b6372fce..b2304b16 100644 --- a/tlib/src/net.cpp +++ b/tlib/src/net.cpp @@ -215,8 +215,6 @@ tlib::socket::socket(socket_domain domain, socket_type type, socket_protocol pro } else { error_code = open_status.error(); } - - local_port = 0; } tlib::socket::~socket() { @@ -276,7 +274,6 @@ void tlib::socket::client_bind(tlib::ip::address server) { auto status = tlib::client_bind(fd, server); if (!status) { _bound = false; - local_port = *status; } else { error_code = status.error(); } @@ -308,7 +305,6 @@ void tlib::socket::connect(tlib::ip::address server, size_t port) { auto status = tlib::connect(fd, server, port); if (status) { _connected = true; - local_port = *status; } else { error_code = status.error(); }