diff options
author | Zbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl> | 2019-11-21 14:41:32 +0100 |
---|---|---|
committer | Zbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl> | 2019-11-22 10:24:32 +0100 |
commit | eec12b7756e2cada16e3b8a9c02f9eaf62df5409 (patch) | |
tree | 6c8c1ebc656435a12714a8072ad8185f59038beb /man/systemd-gpt-auto-generator.xml | |
parent | machine: simplify machine_start_scope() (diff) | |
download | systemd-eec12b7756e2cada16e3b8a9c02f9eaf62df5409.tar.xz systemd-eec12b7756e2cada16e3b8a9c02f9eaf62df5409.zip |
machined: simplify reference handling for units
Before, we'd unref from machine_stop_unit, still keeping the unit name around,
and only forget the name later, when garbage collecting. If we didn't call
manager_stop_unit(), then we wouldn't do the unref. Let's unref at the same
point where we do garbage collection, so that it is always true that
iff we have the name generated with AddRef=1, then have a reference to the unit,
and as soon as we forget the name, we drop the reference.
This should fix the issue when repeated systemd-nspawn --register=yes fails
with "scope already exists" error.
Incidentally, this fixes an error in the code path where r was used instead of q.
Diffstat (limited to 'man/systemd-gpt-auto-generator.xml')
0 files changed, 0 insertions, 0 deletions