diff options
author | Zbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl> | 2015-09-28 13:22:02 -0400 |
---|---|---|
committer | Zbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl> | 2015-09-28 15:09:34 -0400 |
commit | 978c8b6347d61f5a792886ef1875a4df625fd65f (patch) | |
tree | efd1980b90d126c0987289ace1353adc7e9ab6b7 /src/basic/unit-name.c | |
parent | 9dc5db34adbd6fa3d2ac08d9610d401ba69cde93 (diff) |
Move UnitActiveState to basic/
Preparation to allow systemctl to query the list of unit states.
Diffstat (limited to 'src/basic/unit-name.c')
-rw-r--r-- | src/basic/unit-name.c | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/src/basic/unit-name.c b/src/basic/unit-name.c index 8742ee757f..d132dcd173 100644 --- a/src/basic/unit-name.c +++ b/src/basic/unit-name.c @@ -839,6 +839,17 @@ static const char* const unit_load_state_table[_UNIT_LOAD_STATE_MAX] = { DEFINE_STRING_TABLE_LOOKUP(unit_load_state, UnitLoadState); +static const char* const unit_active_state_table[_UNIT_ACTIVE_STATE_MAX] = { + [UNIT_ACTIVE] = "active", + [UNIT_RELOADING] = "reloading", + [UNIT_INACTIVE] = "inactive", + [UNIT_FAILED] = "failed", + [UNIT_ACTIVATING] = "activating", + [UNIT_DEACTIVATING] = "deactivating" +}; + +DEFINE_STRING_TABLE_LOOKUP(unit_active_state, UnitActiveState); + static const char* const unit_dependency_table[_UNIT_DEPENDENCY_MAX] = { [UNIT_REQUIRES] = "Requires", [UNIT_REQUIRES_OVERRIDABLE] = "RequiresOverridable", |