mirror of
https://github.com/systemd/systemd.git
synced 2024-12-27 07:22:31 +03:00
a60f96fcf5
Previously, even if a.service has JoinsNamespaceOf=b.service, the inverse direction of reference was not introduced. Hence, a.service is started earlier than b.service, the namespace will not shared with b.service. Also, even if a.service had the reference to b.service, b.service did not. If b.service is freed earlier, then unit_clear_dependencies() does not clear the reference from a to b, and will cause use-after-free on unit_free() for a.service. Let's make JoinsNamespaceOf=b.service in a.service implies the inverse dependency, i.e. JoinsNamespaceOf=a.service for b.service. Then, we can safely free b.service.
7 lines
142 B
Desktop File
7 lines
142 B
Desktop File
# SPDX-License-Identifier: LGPL-2.1-or-later
|
|
[Service]
|
|
Type=oneshot
|
|
MountAPIVFS=yes
|
|
PrivateTmp=yes
|
|
ExecStart=test -e /tmp/shared-private-file
|