X-Git-Url: https://git.netwichtig.de/gitweb/?a=blobdiff_plain;f=src%2Fsocket.cpp;h=e481846942f0931664c5e39d82ddaad594010d6b;hb=89fc6ca9c66198fe54cce19d59279cd454fc1bd0;hp=16cdebae6d8e22e81fa23cd6a6b09e1587acd7b7;hpb=43d1577839df81d3746092f11ebd1280ca2f85c1;p=user%2Fhenk%2Fcode%2Finspircd.git diff --git a/src/socket.cpp b/src/socket.cpp index 16cdebae6..e48184694 100644 --- a/src/socket.cpp +++ b/src/socket.cpp @@ -111,7 +111,7 @@ void ListenSocket::HandleEvent(EventType, int) if (this->family == AF_INET6) { in_port = ntohs(((sockaddr_in6*)sock_us)->sin6_port); - inet_ntop(AF_INET6, &((const sockaddr_in6*)ip)->sin6_addr, buf, sizeof(buf)); + inet_ntop(AF_INET6, &((const sockaddr_in6*)client)->sin6_addr, buf, sizeof(buf)); socklen_t raddrsz = sizeof(sockaddr_in6); if (getpeername(incomingSockfd, (sockaddr*) raddr, &raddrsz) == 0) inet_ntop(AF_INET6, &((const sockaddr_in6*)raddr)->sin6_addr, target, sizeof(target));