mirror of
https://github.com/Icinga/icinga2.git
synced 2025-04-08 17:05:25 +02:00
Host::GetSeverity(): add braces to if statements
No change in functionality, just makes the code a bit nicer.
This commit is contained in:
parent
c899d52e2f
commit
6443f8997f
@ -180,17 +180,19 @@ int Host::GetSeverity() const
|
||||
} else if (state == HostUp) {
|
||||
severity = 0;
|
||||
} else {
|
||||
if (IsReachable())
|
||||
if (IsReachable()) {
|
||||
severity = 64;
|
||||
else
|
||||
} else {
|
||||
severity = 32;
|
||||
}
|
||||
|
||||
if (IsAcknowledged())
|
||||
if (IsAcknowledged()) {
|
||||
severity += 512;
|
||||
else if (IsInDowntime())
|
||||
} else if (IsInDowntime()) {
|
||||
severity += 256;
|
||||
else
|
||||
} else {
|
||||
severity += 2048;
|
||||
}
|
||||
}
|
||||
|
||||
olock.Unlock();
|
||||
|
Loading…
x
Reference in New Issue
Block a user