From: Zbigniew Jędrzejewski-Szmek Date: Mon, 16 Jan 2017 01:25:35 +0000 (-0500) Subject: coredump: add note about lack of rollback on oom X-Git-Tag: v233~89^2 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=refs%2Fpull%2F4526%2Fhead;p=thirdparty%2Fsystemd.git coredump: add note about lack of rollback on oom --- diff --git a/src/coredump/coredump.c b/src/coredump/coredump.c index 7b11e230bfe..1bb1dbbe8d9 100644 --- a/src/coredump/coredump.c +++ b/src/coredump/coredump.c @@ -1049,7 +1049,9 @@ static int gather_pid_metadata( char **comm_fallback, char **comm_ret, struct iovec *iovec, size_t *n_iovec) { - /* We need 25 empty slots in iovec! */ + /* We need 25 empty slots in iovec! + * Note that if we fail on oom later on, we do not roll-back changes to the iovec + * structure. (It remains valid, with the first n_iovec fields initialized.) */ _cleanup_free_ char *exe = NULL, *comm = NULL; uid_t owner_uid;