diff options
author | Max Kellermann <max@musicpd.org> | 2018-07-17 21:08:41 +0200 |
---|---|---|
committer | Max Kellermann <max@musicpd.org> | 2018-07-17 21:08:41 +0200 |
commit | 5b192beaa5cb8f007b04bb4c52fc2076c12107c6 (patch) | |
tree | ea316e7beb98cbf6b6870d0d545d89f77425d0c7 /src/neighbor | |
parent | ef38330d748742945a781ef520ffd4de2d1f9301 (diff) |
config/Global: remove ConfigBlock::SetUsed() call, let caller do that
This fixes an old bug which caused the "unused" warnings to be
unreliable; only the first block in the list was marked as being
"used", no matter if it was really used, and the rest was never marked
as "used", suppressing all warnings for them.
Diffstat (limited to 'src/neighbor')
-rw-r--r-- | src/neighbor/Glue.cxx | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/neighbor/Glue.cxx b/src/neighbor/Glue.cxx index b55b3d9ad..8ba1013c7 100644 --- a/src/neighbor/Glue.cxx +++ b/src/neighbor/Glue.cxx @@ -54,6 +54,8 @@ NeighborGlue::Init(EventLoop &loop, NeighborListener &listener) { for (const auto *block = config_get_block(ConfigBlockOption::NEIGHBORS); block != nullptr; block = block->next) { + block->SetUsed(); + try { explorers.emplace_front(CreateNeighborExplorer(loop, listener, |