]> git.ipfire.org Git - thirdparty/systemd.git/commit
coredump: create unnamed temporary files if possible (O_TMPFILE) (#3065)
authorEvgeny Vereshchagin <evvers@ya.ru>
Tue, 19 Apr 2016 14:59:47 +0000 (17:59 +0300)
committerLennart Poettering <lennart@poettering.net>
Tue, 19 Apr 2016 14:59:47 +0000 (16:59 +0200)
commit0c7739039b090a2c1f8c894c0e6eb75fc25663a0
tree7f63162c5d077eb3c1a8a6760427dac40f264aff
parent490d20e65dd85628f910299a3925bbff466b2e74
coredump: create unnamed temporary files if possible (O_TMPFILE) (#3065)

Don't leave temporary files if the coredump service is aborted during
the operation

Yeah, these are temporary files that systemd-coredump needs while
processing the coredumps. Of course, if the coredump service is aborted
during the operation we better shouldn't leave those files around. This
is hence a bug to fix in our coredumping code.
See https://github.com/systemd/systemd/issues/2804#issuecomment-210578147

Another option is to simply use O_TMPFILE, and when it is not available
fall back to the current behaviour. After all, the files are cleaned up
eventually, through normal tmpfiles aging, and the offending file
systems are pretty exotic these days, or not in the upstream kernel.

See https://github.com/systemd/systemd/issues/2804#issuecomment-211496707
src/coredump/coredump.c