}
fd = socket(bind_to.family(), SOCK_STREAM, 0);
-
- if (this->fd == -1)
+ if (!HasFd())
return;
#ifdef IPV6_V6ONLY
ListenSocket::~ListenSocket()
{
- if (this->GetFd() > -1)
+ if (this->HasFd())
{
ServerInstance->Logs->Log("SOCKET", LOG_DEBUG, "Shut down listener on fd %d", this->fd);
SocketEngine::Shutdown(this, 2);