]> git.ipfire.org Git - thirdparty/systemd.git/blobdiff - src/core/snapshot.c
util-lib: split string parsing related calls from util.[ch] into parse-util.[ch]
[thirdparty/systemd.git] / src / core / snapshot.c
index 9518e21f36b4f2698cf97bd251b779a9019583d2..da1c99ad12e0f05fcca724ee105784f14173a51c 100644 (file)
 
 #include <errno.h>
 
-#include "unit.h"
+#include "bus-common-errors.h"
+#include "dbus-snapshot.h"
+#include "parse-util.h"
+#include "parse-util.h"
 #include "snapshot.h"
+#include "string-util.h"
 #include "unit-name.h"
-#include "dbus-snapshot.h"
-#include "bus-common-errors.h"
+#include "unit.h"
 
 static const UnitActiveState state_translation_table[_SNAPSHOT_STATE_MAX] = {
         [SNAPSHOT_DEAD] = UNIT_INACTIVE,
@@ -272,13 +275,6 @@ void snapshot_remove(Snapshot *s) {
         unit_add_to_cleanup_queue(UNIT(s));
 }
 
-static const char* const snapshot_state_table[_SNAPSHOT_STATE_MAX] = {
-        [SNAPSHOT_DEAD] = "dead",
-        [SNAPSHOT_ACTIVE] = "active"
-};
-
-DEFINE_STRING_TABLE_LOOKUP(snapshot_state, SnapshotState);
-
 const UnitVTable snapshot_vtable = {
         .object_size = sizeof(Snapshot),
 
@@ -302,6 +298,5 @@ const UnitVTable snapshot_vtable = {
         .active_state = snapshot_active_state,
         .sub_state_to_string = snapshot_sub_state_to_string,
 
-        .bus_interface = "org.freedesktop.systemd1.Snapshot",
         .bus_vtable = bus_snapshot_vtable
 };