Systemd/src/coredump
Lennart Poettering e6a7ec4b8e io-util: add new IOVEC_INIT/IOVEC_MAKE macros
This adds IOVEC_INIT() and IOVEC_MAKE() for initializing iovec structures
from a pointer and a size. On top of these IOVEC_INIT_STRING() and
IOVEC_MAKE_STRING() are added which take a string and automatically
determine the size of the string using strlen().

This patch removes the old IOVEC_SET_STRING() macro, given that
IOVEC_MAKE_STRING() is now useful for similar purposes. Note that the
old IOVEC_SET_STRING() invocations were two characters shorter than the
new ones using IOVEC_MAKE_STRING(), but I think the new syntax is more
readable and more generic as it simply resolves to a C99 literal
structure initialization. Moreover, we can use very similar syntax now
for initializing strings and pointer+size iovec entries. We canalso use
the new macros to initialize function parameters on-the-fly or array
definitions. And given that we shouldn't have so many ways to do the
same stuff, let's just settle on the new macros.

(This also converts some code to use _cleanup_ where dynamically
allocated strings were using IOVEC_SET_STRING() before, to modernize
things a bit)
2017-09-22 15:28:04 +02:00
..
coredump-vacuum.c build-sys: move coredump logic into subdir of its own 2016-02-10 14:32:27 +01:00
coredump-vacuum.h build-sys: move coredump logic into subdir of its own 2016-02-10 14:32:27 +01:00
coredump.c io-util: add new IOVEC_INIT/IOVEC_MAKE macros 2017-09-22 15:28:04 +02:00
coredump.conf build-sys: move coredump logic into subdir of its own 2016-02-10 14:32:27 +01:00
coredumpctl.c coredump: define a macro for a "short bus call timeout" 2017-03-01 18:13:00 +01:00
meson.build meson: use booleans for conf.set and drop unecessary conditionals 2017-05-02 16:29:11 -04:00
stacktrace.c tree-wide: fput[cs]() → fput[cs]_unlocked() wherever that makes sense (#6396) 2017-07-21 10:35:45 +02:00
stacktrace.h build-sys: move coredump logic into subdir of its own 2016-02-10 14:32:27 +01:00
test-coredump-vacuum.c build-sys: move coredump logic into subdir of its own 2016-02-10 14:32:27 +01:00