]> granicus.if.org Git - icinga2/commitdiff
Fix failed assertion in DB IDO
authorMichael Friedrich <michael.friedrich@netways.de>
Mon, 27 Apr 2015 08:59:53 +0000 (10:59 +0200)
committerMichael Friedrich <michael.friedrich@netways.de>
Mon, 27 Apr 2015 09:00:41 +0000 (11:00 +0200)
fixes #9121

lib/icinga/checkable.cpp

index 6ec3294c3c8842b27af3bdb5c701e0dd113cd2d3..a03f4de4d8ca174496c1edba4bf582096a363a32 100644 (file)
@@ -102,8 +102,6 @@ void Checkable::AddGroup(const String& name)
 
 AcknowledgementType Checkable::GetAcknowledgement(void)
 {
-       ASSERT(OwnsLock());
-
        AcknowledgementType avalue = static_cast<AcknowledgementType>(GetAcknowledgementRaw());
 
        if (avalue != AcknowledgementNone) {
@@ -125,12 +123,8 @@ bool Checkable::IsAcknowledged(void)
 
 void Checkable::AcknowledgeProblem(const String& author, const String& comment, AcknowledgementType type, bool notify, double expiry, const MessageOrigin& origin)
 {
-       {
-               ObjectLock olock(this);
-
-               SetAcknowledgementRaw(type);
-               SetAcknowledgementExpiry(expiry);
-       }
+       SetAcknowledgementRaw(type);
+       SetAcknowledgementExpiry(expiry);
 
        if (notify)
                OnNotificationsRequested(this, NotificationAcknowledgement, GetLastCheckResult(), author, comment);
@@ -140,8 +134,6 @@ void Checkable::AcknowledgeProblem(const String& author, const String& comment,
 
 void Checkable::ClearAcknowledgement(const MessageOrigin& origin)
 {
-       ASSERT(OwnsLock());
-
        SetAcknowledgementRaw(AcknowledgementNone);
        SetAcknowledgementExpiry(0);