]> git.ipfire.org Git - thirdparty/systemd.git/commit
sd-journal: various clean-ups and modernizations
authorLennart Poettering <lennart@poettering.net>
Mon, 2 Nov 2015 22:14:30 +0000 (23:14 +0100)
committerLennart Poettering <lennart@poettering.net>
Mon, 2 Nov 2015 23:02:00 +0000 (00:02 +0100)
commitd617408ecbe69db69aefddfcb10a6c054ea46ba0
tree58f6f3ee068eaebc7af6a4e345b26069ae505e65
parent4f52b822b05c373f40fea1a41ae3ade5d5ff558e
sd-journal: various clean-ups and modernizations

- Always print a debug log message about files and directories we cannot
  open right when it happens instead of the caller, thus reducing the
  number of places where we need to generate the debug message.

- Always push the errors we encounter immediately into the error set,
  when we run into them, instead of in the caller. Thus, we never forget
  to push them in.

- Use stack instead of heap memory where we can.

- Make remove_file() void, since it cannot fail anyway and always
  returned 0.

- Make local machine check of journal directories explicit in a
  function, to make things more readable.

- Port to all directory listing loops FOREACH_DIRENT_ALL()

- sd-daemon is library code, hence never log at higher log levels than
  LOG_DEBUG.
src/journal/sd-journal.c