chiark / gitweb /
manager: rename 'maintenance' state to 'failed' to avoid user confusion
[elogind.git] / src / logger.c
index 95d58fc1b3d875cca408f159202621e86be91fdc..5a28c2197fd3c0d9a36f604e453e5afe8e6b31e6 100644 (file)
@@ -38,7 +38,6 @@
 #include "sd-daemon.h"
 #include "tcpwrap.h"
 
-#define STREAM_BUFFER 2048
 #define STREAMS_MAX 256
 #define SERVER_FD_MAX 16
 #define TIMEOUT ((int) (10*MSEC_PER_SEC))
@@ -85,7 +84,7 @@ struct Stream {
 
         bool prefix;
 
-        char buffer[STREAM_BUFFER];
+        char buffer[LINE_MAX];
         size_t length;
 
         LIST_FIELDS(Stream, stream);
@@ -297,7 +296,7 @@ static int stream_process(Stream *s, usec_t ts) {
         int r;
         assert(s);
 
-        if ((l = read(s->fd, s->buffer+s->length, STREAM_BUFFER-s->length)) < 0) {
+        if ((l = read(s->fd, s->buffer+s->length, LINE_MAX-s->length)) < 0) {
 
                 if (errno == EAGAIN)
                         return 0;
@@ -617,7 +616,7 @@ int main(int argc, char *argv[]) {
 
         r = 0;
 
-        log_info("systemd-logger stopped as pid %lu", (unsigned long) getpid());
+        log_debug("systemd-logger stopped as pid %lu", (unsigned long) getpid());
 
 fail:
         sd_notify(false,