mirror of
https://github.com/slsdetectorgroup/slsDetectorPackage.git
synced 2025-06-23 10:07:59 +02:00
fixed conversion for IpAddr
This commit is contained in:
@ -12,8 +12,8 @@ class IpAddr {
|
||||
public:
|
||||
constexpr IpAddr() noexcept = default;
|
||||
explicit constexpr IpAddr(uint32_t address) noexcept : addr_{address} {}
|
||||
IpAddr(const std::string &address);
|
||||
IpAddr(const char *address);
|
||||
explicit IpAddr(const std::string &address);
|
||||
explicit IpAddr(const char *address);
|
||||
std::string str() const;
|
||||
std::string hex() const;
|
||||
std::array<char, 16u> arr() const;
|
||||
|
@ -48,7 +48,7 @@ ServerInterface2 ServerSocket::accept() {
|
||||
}
|
||||
char tc[INET_ADDRSTRLEN]{};
|
||||
inet_ntop(AF_INET, &(clientAddr.sin_addr), tc, INET_ADDRSTRLEN);
|
||||
thisClient = tc;
|
||||
thisClient = IpAddr{tc};
|
||||
return ServerInterface2(newSocket);
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user