nspawn: make use of the new sd_bus_set_close_on_exit() call in nspawn

This commit is contained in:
Lennart Poettering 2018-10-06 18:45:58 +02:00
parent c4e48030cf
commit e5a2d8b5b5
1 changed files with 4 additions and 0 deletions

View File

@ -3974,6 +3974,10 @@ static int run(int master,
r = sd_bus_default_system(&bus);
if (r < 0)
return log_error_errno(r, "Failed to open system bus: %m");
r = sd_bus_set_close_on_exit(bus, false);
if (r < 0)
return log_error_errno(r, "Failed to disable close-on-exit behaviour: %m");
}
if (!arg_keep_unit) {