X-Git-Url: https://www.chiark.greenend.org.uk/ucgi/~ianmdlvl/git?a=blobdiff_plain;f=load-fragment.c;h=b4e0c760093551ed8c7091fa0c6054cd9d74d22e;hb=6e620becc8543e9ea8381fcd779dd932c2464749;hp=b5efbb25e0738ce5ca40f28f3d005ee4effa5046;hpb=932921b5c247f5de09f0e20208534f354f9c0fef;p=elogind.git diff --git a/load-fragment.c b/load-fragment.c index b5efbb25e..b4e0c7600 100644 --- a/load-fragment.c +++ b/load-fragment.c @@ -28,6 +28,7 @@ #include #include #include +#include #include "unit.h" #include "strv.h" @@ -1170,7 +1171,8 @@ static int load_from_path(Unit *u, const char *path) { [UNIT_DEVICE] = "Device", [UNIT_MOUNT] = "Mount", [UNIT_AUTOMOUNT] = "Automount", - [UNIT_SNAPSHOT] = "Snapshot" + [UNIT_SNAPSHOT] = "Snapshot", + [UNIT_SWAP] = "Swap" }; #define EXEC_CONTEXT_CONFIG_ITEMS(context, section) \ @@ -1285,6 +1287,10 @@ static int load_from_path(Unit *u, const char *path) { { "Where", config_parse_path, &u->automount.where, "Automount" }, + { "What", config_parse_path, &u->swap.what, "Swap" }, + { "Priority", config_parse_unsigned, &u->swap.priority, "Swap" }, + { "NoAuto", config_parse_bool, &u->swap.no_auto, "Swap" }, + { NULL, NULL, NULL, NULL } };