]> git.ipfire.org Git - thirdparty/squid.git/commitdiff
Renamed acl_deny_info_list to AclDenyInfoList and moved to own header file in acl/
authorFrancesco Chemolli <kinkie@squid-cache.org>
Wed, 5 Sep 2012 14:49:29 +0000 (16:49 +0200)
committerFrancesco Chemolli <kinkie@squid-cache.org>
Wed, 5 Sep 2012 14:49:29 +0000 (16:49 +0200)
src/SquidConfig.h
src/acl/AclDenyInfoList.h [new file with mode: 0644]
src/acl/Gadgets.cc
src/acl/Gadgets.h
src/acl/Makefile.am
src/cache_cf.cc
src/globals.h
src/mem.cc
src/structs.h

index 835cc3e4f9f8f3c219538e14658b1d3f3f7fff28..1983dcf3b26a5b84e395960710c3050c95d3f2da 100644 (file)
@@ -46,7 +46,7 @@
 #endif
 
 class acl_access;
-class acl_deny_info_list;
+class AclDenyInfoList;
 class acl_size_t;
 class HeaderManglers;
 class refresh_t;
@@ -389,7 +389,7 @@ public:
         acl_access* icap;
 #endif
     } accessList;
-    acl_deny_info_list *denyInfoList;
+    AclDenyInfoList *denyInfoList;
 
     struct {
         size_t list_width;
diff --git a/src/acl/AclDenyInfoList.h b/src/acl/AclDenyInfoList.h
new file mode 100644 (file)
index 0000000..e878970
--- /dev/null
@@ -0,0 +1,47 @@
+#ifndef SQUID_ACLDENYINFOLIST_H_
+#define SQUID_ACLDENYINFOLIST_H_
+/*
+ * DEBUG: section 
+ * AUTHOR: 
+ *
+ * SQUID Web Proxy Cache          http://www.squid-cache.org/
+ * ----------------------------------------------------------
+ *
+ *  Squid is the result of efforts by numerous individuals from
+ *  the Internet community; see the CONTRIBUTORS file for full
+ *  details.   Many organizations have provided support for Squid's
+ *  development; see the SPONSORS file for full details.  Squid is
+ *  Copyrighted (C) 2001 by the Regents of the University of
+ *  California; see the COPYRIGHT file for full details.  Squid
+ *  incorporates software developed and/or copyrighted by other
+ *  sources; see the CREDITS file for full details.
+ *
+ *  This program is free software; you can redistribute it and/or modify
+ *  it under the terms of the GNU General Public License as published by
+ *  the Free Software Foundation; either version 2 of the License, or
+ *  (at your option) any later version.
+ *
+ *  This program is distributed in the hope that it will be useful,
+ *  but WITHOUT ANY WARRANTY; without even the implied warranty of
+ *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ *  GNU General Public License for more details.
+ *
+ *  You should have received a copy of the GNU General Public License
+ *  along with this program; if not, write to the Free Software
+ *  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111, USA.
+ *
+ */
+
+#include "err_type.h"
+#include "acl/AclNameList.h"
+
+class AclDenyInfoList {
+public:
+    err_type err_page_id;
+    char *err_page_name;
+    AclNameList *acl_list;
+    AclDenyInfoList *next;
+};
+
+
+#endif /* SQUID_ACLDENYINFOLIST_H_ */
index b06363ca8427be99e4cdce5a9f750e1ad232e657..f6fd6ba3cb547b5c3e559dd12d2409c612debc50 100644 (file)
@@ -39,6 +39,7 @@
 #include "squid.h"
 #include "acl/Acl.h"
 #include "acl/AclNameList.h"
+#include "acl/AclDenyInfoList.h"
 #include "acl/Checklist.h"
 #include "acl/Strategised.h"
 #include "acl/Gadgets.h"
@@ -50,9 +51,9 @@
 
 /* does name lookup, returns page_id */
 err_type
-aclGetDenyInfoPage(acl_deny_info_list ** head, const char *name, int redirect_allowed)
+aclGetDenyInfoPage(AclDenyInfoList ** head, const char *name, int redirect_allowed)
 {
-    acl_deny_info_list *A = NULL;
+    AclDenyInfoList *A = NULL;
 
     debugs(28, 8, HERE << "got called for " << name);
 
@@ -107,12 +108,12 @@ aclIsProxyAuth(const char *name)
  */
 
 void
-aclParseDenyInfoLine(acl_deny_info_list ** head)
+aclParseDenyInfoLine(AclDenyInfoList ** head)
 {
     char *t = NULL;
-    acl_deny_info_list *A = NULL;
-    acl_deny_info_list *B = NULL;
-    acl_deny_info_list **T = NULL;
+    AclDenyInfoList *A = NULL;
+    AclDenyInfoList *B = NULL;
+    AclDenyInfoList **T = NULL;
     AclNameList *L = NULL;
     AclNameList **Tail = NULL;
 
@@ -124,10 +125,10 @@ aclParseDenyInfoLine(acl_deny_info_list ** head)
         return;
     }
 
-    A = (acl_deny_info_list *)memAllocate(MEM_ACL_DENY_INFO_LIST);
+    A = (AclDenyInfoList *)memAllocate(MEM_ACL_DENY_INFO_LIST);
     A->err_page_id = errorReservePageId(t);
     A->err_page_name = xstrdup(t);
-    A->next = (acl_deny_info_list *) NULL;
+    A->next = (AclDenyInfoList *) NULL;
     /* next expect a list of ACL names */
     Tail = &A->acl_list;
 
@@ -281,13 +282,13 @@ aclDestroyAccessList(acl_access ** list)
 }
 
 /* maex@space.net (06.09.1996)
- *    destroy an acl_deny_info_list */
+ *    destroy an AclDenyInfoList */
 
 void
-aclDestroyDenyInfoList(acl_deny_info_list ** list)
+aclDestroyDenyInfoList(AclDenyInfoList ** list)
 {
-    acl_deny_info_list *a = NULL;
-    acl_deny_info_list *a_next = NULL;
+    AclDenyInfoList *a = NULL;
+    AclDenyInfoList *a_next = NULL;
     AclNameList *l = NULL;
     AclNameList *l_next = NULL;
 
index 38214f546d6f7c1b148ce38b6f4b4502227992b0..aadee845715a27b6966bd01c4b439d366178cf0f 100644 (file)
@@ -4,12 +4,12 @@
 #include "err_type.h"
 
 struct dlink_list;
-class StoreEntry;
-class ConfigParser;
 class acl_access;
 class ACL;
+class AclDenyInfoList;
 class ACLList;
-struct acl_deny_info_list;
+class ConfigParser;
+class StoreEntry;
 class wordlist;
 
 /// \ingroup ACLAPI
@@ -25,11 +25,11 @@ extern void aclParseAclList(ConfigParser &parser, ACLList **);
 /// \ingroup ACLAPI
 extern int aclIsProxyAuth(const char *name);
 /// \ingroup ACLAPI
-extern err_type aclGetDenyInfoPage(acl_deny_info_list ** head, const char *name, int redirect_allowed);
+extern err_type aclGetDenyInfoPage(AclDenyInfoList ** head, const char *name, int redirect_allowed);
 /// \ingroup ACLAPI
-extern void aclParseDenyInfoLine(acl_deny_info_list **);
+extern void aclParseDenyInfoLine(AclDenyInfoList **);
 /// \ingroup ACLAPI
-extern void aclDestroyDenyInfoList(acl_deny_info_list **);
+extern void aclDestroyDenyInfoList(AclDenyInfoList **);
 /// \ingroup ACLAPI
 extern wordlist *aclDumpGeneric(const ACL *);
 /// \ingroup ACLAPI
index 580eed0b7ca120f48dc7467d9c044d3498cf9999..500018d89cfab04ba53e1959880118c02fa2bcc9 100644 (file)
@@ -106,6 +106,7 @@ libacls_la_SOURCES = \
        UserData.h \
        \
        AclNameList.h \
+       AclDenyInfoList.h \
        Gadgets.cc \
        Gadgets.h
 
index 9078686fe11155876af05b2723a1a6102e1d8b0a..c847a9c324bb458083b6feadd1213faeaa5760bf 100644 (file)
@@ -32,6 +32,7 @@
 
 #include "squid.h"
 #include "acl/Acl.h"
+#include "acl/AclDenyInfoList.h"
 #include "acl/AclNameList.h"
 #include "acl/Gadgets.h"
 #include "acl/MethodData.h"
@@ -211,9 +212,9 @@ static void parse_http_header_replace(HeaderManglers **manglers);
 static void dump_HeaderWithAclList(StoreEntry * entry, const char *name, HeaderWithAclList *headers);
 static void parse_HeaderWithAclList(HeaderWithAclList **header);
 static void free_HeaderWithAclList(HeaderWithAclList **header);
-static void parse_denyinfo(acl_deny_info_list ** var);
-static void dump_denyinfo(StoreEntry * entry, const char *name, acl_deny_info_list * var);
-static void free_denyinfo(acl_deny_info_list ** var);
+static void parse_denyinfo(AclDenyInfoList ** var);
+static void dump_denyinfo(StoreEntry * entry, const char *name, AclDenyInfoList * var);
+static void free_denyinfo(AclDenyInfoList ** var);
 
 #if USE_WCCPv2
 static void parse_IpAddress_list(Ip::Address_list **);
@@ -2436,7 +2437,7 @@ free_cachemgrpasswd(cachemgr_passwd ** head)
 }
 
 static void
-dump_denyinfo(StoreEntry * entry, const char *name, acl_deny_info_list * var)
+dump_denyinfo(StoreEntry * entry, const char *name, AclDenyInfoList * var)
 {
     AclNameList *a;
 
@@ -2453,16 +2454,16 @@ dump_denyinfo(StoreEntry * entry, const char *name, acl_deny_info_list * var)
 }
 
 static void
-parse_denyinfo(acl_deny_info_list ** var)
+parse_denyinfo(AclDenyInfoList ** var)
 {
     aclParseDenyInfoLine(var);
 }
 
 void
-free_denyinfo(acl_deny_info_list ** list)
+free_denyinfo(AclDenyInfoList ** list)
 {
-    acl_deny_info_list *a = NULL;
-    acl_deny_info_list *a_next = NULL;
+    AclDenyInfoList *a = NULL;
+    AclDenyInfoList *a_next = NULL;
     AclNameList *l = NULL;
     AclNameList *l_next = NULL;
 
index 8997454cf2723ed36c63f8311bf948c332314ea1..f91d085a1e343125f1b0439cc547cad5d27b52d6 100644 (file)
@@ -40,6 +40,7 @@
 #include "defines.h"
 
 /* for iostats */
+#include "acl/AclDenyInfoList.h"
 #include "structs.h"
 
 extern char *ConfigFile;       /* NULL */
@@ -87,7 +88,7 @@ extern int DnsSocketB;                /* -1 */
 extern int n_disk_objects;     /* 0 */
 extern iostats IOStats;
 
-extern struct acl_deny_info_list *DenyInfoList;        /* NULL */
+extern AclDenyInfoList *DenyInfoList;  /* NULL */
 
 extern struct timeval squid_start;
 extern int starting_up;        /* 1 */
index dec2049092f84c8c0af98d415a9245933d111da2..d68030d7f0b338e9b2cb8482225a9e77303e3662 100644 (file)
@@ -31,6 +31,7 @@
  */
 
 #include "squid.h"
+#include "acl/AclDenyInfoList.h"
 #include "acl/AclNameList.h"
 #include "ClientInfo.h"
 #include "event.h"
@@ -450,8 +451,8 @@ Mem::Init(void)
     memDataInit(MEM_16K_BUF, "16K Buffer", 16384, 10, false);
     memDataInit(MEM_32K_BUF, "32K Buffer", 32768, 10, false);
     memDataInit(MEM_64K_BUF, "64K Buffer", 65536, 10, false);
-    memDataInit(MEM_ACL_DENY_INFO_LIST, "acl_deny_info_list",
-                sizeof(acl_deny_info_list), 0);
+    memDataInit(MEM_ACL_DENY_INFO_LIST, "AclDenyInfoList",
+                sizeof(AclDenyInfoList), 0);
     memDataInit(MEM_ACL_NAME_LIST, "acl_name_list", sizeof(AclNameList), 0);
 #if USE_CACHE_DIGESTS
 
index 3b4b1dd103fd4471621ce09450c62c11249fbf32..f3d192a001d68720b434eff145a89c77ffa5b7d4 100644 (file)
 
 #define PEER_MULTICAST_SIBLINGS 1
 
-struct acl_deny_info_list {
-    err_type err_page_id;
-    char *err_page_name;
-    AclNameList *acl_list;
-    acl_deny_info_list *next;
-};
-
 class ACLChecklist;
 
 #if SQUID_SNMP