mirror of
https://github.com/clearlinux/systemd-stable.git
synced 2026-09-06 13:41:31 +00:00
load-modules: properly return a failing error code if some module fails to load
This is the missing part of b857193b1d.
This commit is contained in:
@@ -286,9 +286,11 @@ int main(int argc, char *argv[]) {
|
||||
r = k;
|
||||
}
|
||||
|
||||
r = conf_files_list_nulstr(&files, ".conf", NULL, conf_file_dirs);
|
||||
if (r < 0) {
|
||||
log_error("Failed to enumerate modules-load.d files: %s", strerror(-r));
|
||||
k = conf_files_list_nulstr(&files, ".conf", NULL, conf_file_dirs);
|
||||
if (k < 0) {
|
||||
log_error("Failed to enumerate modules-load.d files: %s", strerror(-k));
|
||||
if (r == 0)
|
||||
r = k;
|
||||
goto finish;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user