summaryrefslogtreecommitdiff
path: root/src/logger.c
diff options
context:
space:
mode:
authorLennart Poettering <lennart@poettering.net>2010-06-16 15:41:29 +0200
committerLennart Poettering <lennart@poettering.net>2010-06-16 15:41:29 +0200
commit0213c3f8102bdc934c629d11a44ca0b408762287 (patch)
tree743fcd1210de5bf35a271b64d5103487fc5f7ad4 /src/logger.c
parent18c78fb1af5415bb6f87d9c7cae1f9c60e14ae24 (diff)
socket: add optional libwrap support
Diffstat (limited to 'src/logger.c')
-rw-r--r--src/logger.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/logger.c b/src/logger.c
index 48eee6cd12..de4dfad386 100644
--- a/src/logger.c
+++ b/src/logger.c
@@ -36,6 +36,7 @@
#include "log.h"
#include "list.h"
#include "sd-daemon.h"
+#include "tcpwrap.h"
#define STREAM_BUFFER 2048
#define STREAMS_MAX 256
@@ -340,6 +341,11 @@ static int stream_new(Server *s, int server_fd) {
return 0;
}
+ if (!socket_tcpwrap(fd, "systemd-logger")) {
+ close_nointr_nofail(fd);
+ return 0;
+ }
+
if (!(stream = new0(Stream, 1))) {
close_nointr_nofail(fd);
return -ENOMEM;