Module: check_mk
Branch: master
Commit: 5e4254176958af6d81e9c7bb0c66374f2c8ecb61
URL:
http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=5e4254176958af…
Author: Jukka Aro <ja(a)mathias-kettner.de>
Date: Fri Mar 16 16:05:00 2018 +0100
Win-agent: remove dead code in SectionPerfcounter
The option _toggle_if_missing was never used in this section.
---
agents/windows/build_version | 2 +-
agents/windows/sections/SectionPerfcounter.cc | 5 -----
agents/windows/sections/SectionPerfcounter.h | 4 ----
3 files changed, 1 insertion(+), 10 deletions(-)
diff --git a/agents/windows/build_version b/agents/windows/build_version
index 90a4e98..55b22ed 100644
--- a/agents/windows/build_version
+++ b/agents/windows/build_version
@@ -1 +1 @@
-3184
+3186
diff --git a/agents/windows/sections/SectionPerfcounter.cc
b/agents/windows/sections/SectionPerfcounter.cc
index 9b57cad..6de4240 100644
--- a/agents/windows/sections/SectionPerfcounter.cc
+++ b/agents/windows/sections/SectionPerfcounter.cc
@@ -57,11 +57,6 @@ SectionPerfcounter::SectionPerfcounter(const std::string
&outputName,
: Section(outputName, configName, env, logger, winapi)
, _nameNumberMap(nameNumberMap) {}
-SectionPerfcounter *SectionPerfcounter::withToggleIfMissing() {
- _toggle_if_missing = true;
- return this;
-}
-
bool SectionPerfcounter::produceOutputInner(
std::ostream &out, const std::optional<std::string> &) {
Debug(_logger) << "SectionPerfcounter::produceOutputInner";
diff --git a/agents/windows/sections/SectionPerfcounter.h
b/agents/windows/sections/SectionPerfcounter.h
index 50568f9..931d815 100644
--- a/agents/windows/sections/SectionPerfcounter.h
+++ b/agents/windows/sections/SectionPerfcounter.h
@@ -55,16 +55,12 @@ public:
NameBaseNumberMap &nameNumberMap, Logger *logger,
const WinApiAdaptor &winapi);
- SectionPerfcounter *withToggleIfMissing();
-
protected:
virtual bool produceOutputInner(
std::ostream &out, const std::optional<std::string> &) override;
private:
unsigned char separator() const override { return ','; }
-
- bool _toggle_if_missing{false};
time_t _disabled_until{0};
NameBaseNumberMap &_nameNumberMap;
};