From 67cbbef0c8ae18d6f50c479ea2dc70012840bd48 Mon Sep 17 00:00:00 2001 From: Amos Jeffries Date: Sun, 30 Aug 2015 13:36:48 -0700 Subject: [PATCH] Fix regression in rev.14268 My bad cut-n-paste resulted in wrong locking sequence. Fixing that reveals that the validity check on the return result triggers cases of cbdata 'locks > 0' assertions. The validity test is not currently needed by the fastCheck code which preserves the value. So removing for now. --- src/acl/Checklist.h | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/acl/Checklist.h b/src/acl/Checklist.h index bae3e8efce..4ccbb4f0c7 100644 --- a/src/acl/Checklist.h +++ b/src/acl/Checklist.h @@ -165,14 +165,14 @@ public: virtual bool hasReply() const = 0; /// change the current ACL list - /// \return a pointer to the old list, or NULL if that is no longer CBDATA-valid + /// \return a pointer to the old list value (may be nullptr) const Acl::Tree *changeAcl(const Acl::Tree *t) { const Acl::Tree *old = accessList; if (t != accessList) { - accessList = cbdataReference(t); cbdataReferenceDone(accessList); + accessList = cbdataReference(t); } - return cbdataReferenceValid(old) ? old : nullptr; + return old; } private: -- 2.47.3