]> git.ipfire.org Git - thirdparty/systemd.git/commit
preset-all: continue on errors, report more errors
authorZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>
Tue, 7 May 2024 16:54:24 +0000 (18:54 +0200)
committerZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>
Wed, 8 May 2024 06:18:55 +0000 (08:18 +0200)
commita4f0e0da3573a10bc5404142be8799418760b1d1
tree462c7bad64babd5d51b5b9a509fc5052f4319e44
parent3473c842fa4d41d873acd076f227a80c69d44450
preset-all: continue on errors, report more errors

Firstly, if we encounter an error when iterating over the directory, gather
the error but continue. This is unlikely to happen, but if it happens, then
it doesn't seem very useful to break the preset processing at a random
point. If we can't process a unit — too bad, but since we already might
have processed some units earlier, we might as well try to process the
remaining ones.

Secondly, add missing error codes for units that are in a bad state to the
exclusion list. Those, we report them in the changes list, but consider the
whole operation a success. (-ETXTBSY and -ENOLINK were missing.)

Thirdly, add a message generator for -ENOLINK.

Fixes https://github.com/systemd/systemd/issues/21224.
src/shared/install.c