]> git.ipfire.org Git - thirdparty/systemd.git/commit - src/core/scope.c
manager: move various fields that declare unit defaults into a new structure UnitDefaults
authorLennart Poettering <lennart@poettering.net>
Fri, 8 Sep 2023 11:37:52 +0000 (13:37 +0200)
committerLennart Poettering <lennart@poettering.net>
Fri, 8 Sep 2023 12:19:45 +0000 (14:19 +0200)
commitc9e120e06f929d8f4bbc4faaf87d641c6938dc08
treeedf805cdf2199496f3854a1118f0013bc99279ac
parentb8f18c3089319796d5bc3d33fb0779b0de5aba7b
manager: move various fields that declare unit defaults into a new structure UnitDefaults

This adds a new structure UnitDefaults which embedds the various default
settings for units we maintain. We so far maintained two sets of
variables for this, one in main.c as static variables and one in the
Manager structure. This moves them into a common structure.

This is most just search/replace, i.e. very dumb refactoring.

The fact that we now use a common structure for this allows us further
refactorings later.

Inspired by the discussions on #27890
16 files changed:
src/core/dbus-manager.c
src/core/device.c
src/core/execute.c
src/core/load-fragment.c
src/core/main.c
src/core/manager.c
src/core/manager.h
src/core/mount.c
src/core/scope.c
src/core/service.c
src/core/socket.c
src/core/swap.c
src/core/timer.c
src/core/unit.c
src/test/test-cgroup-mask.c
src/test/test-execute.c