diff options
author | Daniel Mack <github@zonque.org> | 2016-01-22 09:47:59 +0100 |
---|---|---|
committer | Daniel Mack <github@zonque.org> | 2016-01-22 09:47:59 +0100 |
commit | 371859d6b55478f1c8d04930f92d52b32ddfdf95 (patch) | |
tree | 9078a5ec96825fe1d3331c0b1ac5c0bfbb17f4c2 /src/journal-remote | |
parent | 07313a18263ca6f2e2a49ee4fba79aa6249ff398 (diff) | |
parent | 366b7db4b65b994cd33cf4fd3c1be429be561307 (diff) |
Merge pull request #2080 from chaloulo/split-mode-host-remove-port-from-journal-filename
journal-remote: split-mode=host, remove port from journal filename
Diffstat (limited to 'src/journal-remote')
-rw-r--r-- | src/journal-remote/journal-remote.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/journal-remote/journal-remote.c b/src/journal-remote/journal-remote.c index 3d71685b33..e7003da9c1 100644 --- a/src/journal-remote/journal-remote.c +++ b/src/journal-remote/journal-remote.c @@ -621,7 +621,7 @@ static int request_handler( if (r < 0) return code; } else { - r = getnameinfo_pretty(fd, &hostname); + r = getpeername_pretty(fd, false, &hostname); if (r < 0) return mhd_respond(connection, MHD_HTTP_INTERNAL_SERVER_ERROR, "Cannot check remote hostname"); @@ -879,7 +879,7 @@ static int remoteserver_init(RemoteServer *s, } else if (sd_is_socket(fd, AF_UNSPEC, 0, false)) { char *hostname; - r = getnameinfo_pretty(fd, &hostname); + r = getpeername_pretty(fd, false, &hostname); if (r < 0) return log_error_errno(r, "Failed to retrieve remote name: %m"); |