]> git.ipfire.org Git - thirdparty/squid.git/commitdiff
Documented that ACLs should be refcounted.
authorAlex Rousskov <rousskov@measurement-factory.com>
Mon, 2 Dec 2013 00:36:24 +0000 (17:36 -0700)
committerAlex Rousskov <rousskov@measurement-factory.com>
Mon, 2 Dec 2013 00:36:24 +0000 (17:36 -0700)
Refcounting would avoid ACL destruction problems (when some ACLs use other
ACLs or when an ACL goes async during reconfigure) and may even reduce
problems with AclMatchedName.

src/acl/Acl.h
src/acl/InnerNode.h

index 6b82937f44afe2631f5190e952eb94896174f1fc..dc61d568f4207226edbd25842c6b2a7572c10d6b 100644 (file)
@@ -135,7 +135,7 @@ public:
 
     char name[ACL_NAME_SZ];
     char *cfgline;
-    ACL *next;
+    ACL *next; // XXX: remove or at least use refcounting
     ACLFlags flags; ///< The list of given ACL flags
     bool registered; ///< added to Config.aclList and can be reused via by FindByName()
 
@@ -244,6 +244,7 @@ public:
 MEMPROXY_CLASS_INLINE(acl_proxy_auth_match_cache);
 
 /// \ingroup ACLAPI
+/// XXX: find a way to remove or at least use a refcounted ACL pointer
 extern const char *AclMatchedName;     /* NULL */
 
 #endif /* SQUID_ACL_H */
index 6f3b14446b85fe6c4fb90ad1266336e4b378b250..bd20dd5d258d6525e3bccafd06bbe587be73c801 100644 (file)
@@ -40,6 +40,7 @@ protected:
     /* ACL API */
     virtual int match(ACLChecklist *checklist);
 
+    // XXX: use refcounting instead of raw pointers
     std::vector<ACL*> nodes; ///< children nodes of this intermediate node
 };