]> git.ipfire.org Git - thirdparty/systemd.git/commit - src/journal/journald.c
journald: allow additional payload in server_driver_message
authorZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>
Sun, 8 Nov 2015 19:05:55 +0000 (14:05 -0500)
committerZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>
Sun, 24 Jan 2016 00:49:00 +0000 (19:49 -0500)
commit8a03c9ef744e13dc700a7e7ca6cae8afdcf0d71c
tree096c53fd5da8339ebf14e8ebc03378a520818ff7
parentca8625e9f9f1e0ec11d9976436eb95ec8651f8d4
journald: allow additional payload in server_driver_message

The code to format the iovec is shared with log.c. All call sites to
server_driver_message are changed to include the additional "MESSAGE="
part, but the new functionality is not used and change in functionality
is not expected.

iovec is preallocated, so the maximum number of messages is limited.
In server_driver_message N_IOVEC_PAYLOAD_FIELDS is currently set to 1.

New code is not oom safe, it will fail if memory cannot be allocated.
This will be fixed in subsequent commit.
src/basic/log.c
src/basic/log.h
src/journal/journald-kmsg.c
src/journal/journald-server.c
src/journal/journald-server.h
src/journal/journald-syslog.c
src/journal/journald.c