mirror of https://github.com/Icinga/icinga2.git
Merge pull request #8599 from Icinga/bugfux/check-if-cr-is-not-nullptr-while-writing-history-8592
IcingaDB: Check whether or not cr is nullptr
This commit is contained in:
commit
6abab6bddc
|
@ -1324,7 +1324,7 @@ void IcingaDB::SendSentNotification(
|
|||
"notification_id", GetObjectIdentifier(notification),
|
||||
"host_id", GetObjectIdentifier(host),
|
||||
"type", Convert::ToString(type),
|
||||
"state", Convert::ToString(service ? Convert::ToLong(cr->GetState()) : Convert::ToLong(Host::CalculateState(cr->GetState()))),
|
||||
"state", Convert::ToString(cr ? service ? Convert::ToLong(cr->GetState()) : Convert::ToLong(Host::CalculateState(cr->GetState())) : 99),
|
||||
"previous_hard_state", Convert::ToString(GetPreviousState(checkable, service, StateTypeHard)),
|
||||
"author", Utility::ValidateUTF8(author),
|
||||
"text", Utility::ValidateUTF8(finalText),
|
||||
|
|
Loading…
Reference in New Issue