MCPcopy Create free account
hub / github.com/Icinga/icinga2 / GetHostState

Method GetHostState

lib/db_ido/dbevents.cpp:1479–1487  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1477}
1478
1479int DbEvents::GetHostState(const Host::Ptr& host)
1480{
1481 int currentState = host->GetState();
1482
1483 if (currentState != HostUp && !host->IsReachable())
1484 currentState = 2; /* hardcoded compat state */
1485
1486 return currentState;
1487}
1488
1489String DbEvents::GetHostStateString(const Host::Ptr& host)
1490{

Callers

nothing calls this directly

Calls 2

GetStateMethod · 0.45
IsReachableMethod · 0.45

Tested by

no test coverage detected