/*
- * $Id: cache_cf.cc,v 1.200 1997/07/07 05:29:39 wessels Exp $
+ * $Id: cache_cf.cc,v 1.201 1997/07/14 04:27:37 wessels Exp $
*
* DEBUG: section 3 Configuration File Parsing
* AUTHOR: Harvest Derived
static void
free_cachedir(struct _cacheSwap *swap)
{
- assert(0);
+ SwapDir *s;
+ int i;
+ for (i = 0; i<swap->n_configured; i++) {
+ s = swap->swapDirs+i;
+ xfree(s->path);
+ filemapFreeMemory(s->map);
+ }
+ safe_free(swap->swapDirs);
+ swap->swapDirs = NULL;
+ swap->n_allocated = 0;
+ swap->n_configured = 0;
}
static void
static void
free_cachemgrpasswd(cachemgr_passwd **head)
{
- assert(0);
+ cachemgr_passwd *p;
+ while ((p = *head)) {
+ *head = p->next;
+ xfree(p->passwd);
+ xfree(p);
+ }
}
aclParseDenyInfoLine(var);
}
-static void
-free_denyinfo(acl_deny_info_list **head)
-{
- assert(0);
+void
+free_denyinfo(acl_deny_info_list **list)
+{
+ struct _acl_deny_info_list *a = NULL;
+ struct _acl_deny_info_list *a_next = NULL;
+ struct _acl_name_list *l = NULL;
+ struct _acl_name_list *l_next = NULL;
+ for (a = *list; a; a = a_next) {
+ for (l = a->acl_list; l; l = l_next) {
+ l_next = l->next;
+ safe_free(l);
+ }
+ a_next = a->next;
+ safe_free(a);
+ }
+ *list = NULL;
}
-
static void
parse_peeracl(void)
{
NAME: mcast_groups
TYPE: wordlist
LOC: Config.mcast_group_list
-DEFAULT: NULL
+DEFAULT: none
DOC_START
This tag specifies a list of multicast groups which your
server should join to receive multicasted ICP requests.
NAME: cache_peer cache_host
TYPE: cache_peer
-DEFAULT: NULL
+DEFAULT: none
LOC: Config.peers
DOC_START
To specify other caches in a hierarchy, use the format:
NAME: hierarchy_stoplist
TYPE: wordlist
-DEFAULT: NULL
+DEFAULT: none
LOC: Config.hierarchy_stoplist
DOC_START
A list of words which, if found in a URL, cause the object to
NAME: cache_stoplist
TYPE: wordlist
-DEFAULT: NULL
+DEFAULT: none
LOC: Config.cache_stoplist
DOC_START
A list of words which, if found in a URL, cause the object to
NAME: cache_stoplist_pattern
TYPE: regexlist
LOC: Config.cache_stop_relist
-DEFAULT: NULL
+DEFAULT: none
DOC_START
Just like 'cache_stoplist' but you can use regular expressions
instead of simple string matching. There is no default.
NAME: cache_swap_log
TYPE: string
LOC: Config.Log.swap
-DEFAULT: NULL
+DEFAULT: none
DOC_START
Location for the cache "swap log." This log file holds the
metadata of objects saved on disk. It is used to rebuild the
#-----------------------------------------------------------------------------
NAME: wais_relay_host
TYPE: string
-DEFAULT: NULL
+DEFAULT: none
LOC: Config.Wais.relayHost
DOC_NONE
NAME: refresh_pattern
TYPE: refreshpattern
LOC: Config.Refresh
-DEFAULT: NONE
+DEFAULT: none
DOC_START
usage: refresh_pattern regex min percent max
NAME: cache_effective_user
TYPE: string
-DEFAULT: NONE
+DEFAULT: none
LOC: Config.effectiveUser
DOC_NONE
NAME: cache_effective_group
TYPE: string
-DEFAULT: NONE
+DEFAULT: none
LOC: Config.effectiveGroup
DOC_START
If the cache is run as root, it will change its effective/real
NAME: ssl_proxy
TYPE: cache_peer
LOC: Config.sslProxy
-DEFAULT: NULL
+DEFAULT: none
DOC_START
Specify a hostname and port number where all SSL requests
should be forwarded to.
NAME: passthrough_proxy
TYPE: cache_peer
LOC: Config.passProxy
-DEFAULT: NULL
+DEFAULT: none
DOC_START
Specify a hostname and port number where all non-GET (i.e.
POST, PUT) requests should be forwarded to.
NAME: proxy_auth_passwd
TYPE: string
LOC: Config.proxyAuth.File
-DEFAULT: NULL
+DEFAULT: none
DOC_NONE
NAME: proxy_auth_ignore
TYPE: regexlist
LOC: Config.proxyAuth.IgnoreDomains
-DEFAULT: NULL
+DEFAULT: none
DOC_START
'passwd_file' is an apache-style file of passwords for
authenticated proxy access Looks like user:password, with the
/*
- * $Id: cf_gen.cc,v 1.4 1997/07/07 05:29:41 wessels Exp $
+ * $Id: cf_gen.cc,v 1.5 1997/07/14 04:27:38 wessels Exp $
*
* DEBUG: section 1 Startup and Main Loop
* AUTHOR: Max Okumoto
"void\n"
"default_all(void)\n"
"{\n"
+ "\tcfg_filename = \"Default Configuration\";\n"
);
for (entry = head; entry != NULL; entry = entry->next) {
assert(entry->name);
entry->default_value);
}
}
+ fprintf(fp, "\tcfg_filename = NULL;\n");
fprintf(fp, "}\n\n");
return rc;
}
"{\n"
"\tint\tresult = 1;\n"
"\tchar\t*token;\n"
- "\n"
+ "\tdebug(0,10)(\"parse_line: %%s\\n\", buff);\n"
"\tif ((token = strtok(buff, w_space)) == NULL) {\n"
"\t\t/* ignore empty lines */\n"
);