Skip to content

Commit 3da9b34

Browse files
lePicimichalvasko
authored andcommitted
session server BUGFIX parameter in inet_ntop func
1 parent 90ff024 commit 3da9b34

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

src/session_server.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -384,7 +384,7 @@ sock_host_inet(const struct sockaddr_in *addr, char **host, uint16_t *port)
384384
return -1;
385385
}
386386

387-
if (!inet_ntop(AF_INET, &addr->sin_addr.s_addr, *host, INET_ADDRSTRLEN)) {
387+
if (!inet_ntop(AF_INET, &addr->sin_addr, *host, INET_ADDRSTRLEN)) {
388388
ERR("inet_ntop failed(%s).");
389389
free(*host);
390390
*host = NULL;
@@ -415,7 +415,7 @@ sock_host_inet6(const struct sockaddr_in6 *addr, char **host, uint16_t *port)
415415
return -1;
416416
}
417417

418-
if (!inet_ntop(AF_INET6, &addr->sin6_addr.s6_addr, *host, INET6_ADDRSTRLEN)) {
418+
if (!inet_ntop(AF_INET6, &addr->sin6_addr, *host, INET6_ADDRSTRLEN)) {
419419
ERR("inet_ntop failed(%s).");
420420
free(*host);
421421
*host = NULL;

0 commit comments

Comments
 (0)