diff options
author | Max Kellermann <max@duempel.org> | 2016-03-05 20:48:37 +0100 |
---|---|---|
committer | Max Kellermann <max@duempel.org> | 2016-03-05 20:48:37 +0100 |
commit | c0bda1b1032050ce7d3dfca6926957bc3c34ee5a (patch) | |
tree | 183c0f1fb8dcf91e60563c28a3f729d0c12dafae /src/Idle.cxx | |
parent | 0e87ce4680df5cc66225b7a20f1c09938ae885cd (diff) |
Idle: move flags to IdleFlags.hxx
Diffstat (limited to 'src/Idle.cxx')
-rw-r--r-- | src/Idle.cxx | 39 |
1 files changed, 0 insertions, 39 deletions
diff --git a/src/Idle.cxx b/src/Idle.cxx index d0f43a3d7..4280c4b5e 100644 --- a/src/Idle.cxx +++ b/src/Idle.cxx @@ -26,7 +26,6 @@ #include "Idle.hxx" #include "Main.hxx" #include "Instance.hxx" -#include "util/ASCII.hxx" #include <atomic> @@ -34,23 +33,6 @@ static std::atomic_uint idle_flags; -static const char *const idle_names[] = { - "database", - "stored_playlist", - "playlist", - "player", - "mixer", - "output", - "options", - "sticker", - "update", - "subscription", - "message", - "neighbor", - "mount", - nullptr -}; - void idle_add(unsigned flags) { @@ -67,24 +49,3 @@ idle_get(void) { return idle_flags.exchange(0); } - -const char*const* -idle_get_names(void) -{ - return idle_names; -} - -unsigned -idle_parse_name(const char *name) -{ -#if !CLANG_CHECK_VERSION(3,6) - /* disabled on clang due to -Wtautological-pointer-compare */ - assert(name != nullptr); -#endif - - for (unsigned i = 0; idle_names[i] != nullptr; ++i) - if (StringEqualsCaseASCII(name, idle_names[i])) - return 1 << i; - - return 0; -} |