add 'network.find_free_port' function

This commit is contained in:
MihailRis 2025-11-15 16:18:34 +03:00
parent 5b3e88bbf1
commit 1f1cb22e4d
4 changed files with 34 additions and 0 deletions

View file

@ -88,6 +88,8 @@ namespace network {
[[nodiscard]] Connection* getConnection(u64id_t id, bool includePrivate);
[[nodiscard]] Server* getServer(u64id_t id, bool includePrivate) const;
int findFreePort() const;
u64id_t connectTcp(
const std::string& address,
int port,