]> git.ipfire.org Git - thirdparty/systemd.git/commit
core: do not leak resources when handling stale alias state on reload (#41986)
authorChris Down <chris@chrisdown.name>
Wed, 13 May 2026 12:25:08 +0000 (21:25 +0900)
committerGitHub <noreply@github.com>
Wed, 13 May 2026 12:25:08 +0000 (21:25 +0900)
commitc301966df770962d2fce4baba51214073d192d45
tree893386b33338798360b350b9e939f0e5fc180195
parente28aab8840cbec43830af5c1520e9d9e123ad896
parent4f7089f0c740b9b0b5e55913282b61d851991562
core: do not leak resources when handling stale alias state on reload (#41986)

The fix for the corrupted state when units become aliased on reload
leaks the now-aliased unit's resources, which become untracked and
essentially lost.

While fixing the state corruption is of course necessary, leaking
processes/etc. is not ideal for a system and service manager, so
instead attempt to keep track of them by creating stub units
on-the-fly.
This way resources are not leaked, there are clear indications of
where they moved, and all state can be tracked as expected.
src/core/manager-serialize.c