chiark / gitweb /
journald: use SCM_SECURITY to race-freely determine peer SELinux label
[elogind.git] / src / log.c
index 0594f7fde59cc208cc5940e31386f598d17d0545..e1f511cca6189d87c995bad265d6fa760bc99065 100644 (file)
--- a/src/log.c
+++ b/src/log.c
@@ -33,6 +33,8 @@
 #include "macro.h"
 #include "socket-util.h"
 
+#define SNDBUF_SIZE (8*1024*1024)
+
 static LogTarget log_target = LOG_TARGET_CONSOLE;
 static int log_max_level = LOG_INFO;
 
@@ -127,6 +129,8 @@ static int create_log_socket(int type) {
         if (fd < 0)
                 return -errno;
 
+        fd_inc_sndbuf(fd, SNDBUF_SIZE);
+
         return fd;
 }
 
@@ -621,11 +625,11 @@ _noreturn_ static void log_assert(const char *text, const char *file, int line,
 }
 #pragma GCC diagnostic pop
 
-void log_assert_failed(const char *text, const char *file, int line, const char *func) {
+_noreturn_ void log_assert_failed(const char *text, const char *file, int line, const char *func) {
         log_assert(text, file, line, func, "Assertion '%s' failed at %s:%u, function %s(). Aborting.");
 }
 
-void log_assert_failed_unreachable(const char *text, const char *file, int line, const char *func) {
+_noreturn_ void log_assert_failed_unreachable(const char *text, const char *file, int line, const char *func) {
         log_assert(text, file, line, func, "Code should not be reached '%s' at %s:%u, function %s(). Aborting.");
 }