mirror of
https://github.com/Icinga/icinga2.git
synced 2025-07-27 07:34:15 +02:00
parent
2720333d6e
commit
0f496c0b55
@ -134,9 +134,15 @@ void PluginUtility::ExecuteCommand(const Command::Ptr& commandObj, const Checkab
|
|||||||
if (!missingMacro.IsEmpty())
|
if (!missingMacro.IsEmpty())
|
||||||
continue;
|
continue;
|
||||||
|
|
||||||
|
int value;
|
||||||
|
|
||||||
|
if (set_if_resolved == "true")
|
||||||
|
value = 1;
|
||||||
|
else if (set_if_resolved == "false")
|
||||||
|
value = 0;
|
||||||
|
else {
|
||||||
try {
|
try {
|
||||||
if (!Convert::ToLong(set_if_resolved))
|
value = Convert::ToLong(set_if_resolved);
|
||||||
continue;
|
|
||||||
} catch (const std::exception& ex) {
|
} catch (const std::exception& ex) {
|
||||||
/* tried to convert a string */
|
/* tried to convert a string */
|
||||||
Log(LogWarning, "PluginUtility")
|
Log(LogWarning, "PluginUtility")
|
||||||
@ -144,6 +150,10 @@ void PluginUtility::ExecuteCommand(const Command::Ptr& commandObj, const Checkab
|
|||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (!value)
|
||||||
|
continue;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
argval = arginfo;
|
argval = arginfo;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user