]> git.ipfire.org Git - thirdparty/squid.git/commitdiff
- removed snmp_config_file option (not used)
authorwessels <>
Fri, 6 Feb 1998 13:44:31 +0000 (13:44 +0000)
committerwessels <>
Fri, 6 Feb 1998 13:44:31 +0000 (13:44 +0000)
- added aclDumpTimeSpec()

src/acl.cc
src/cf.data.pre
src/squid.h

index 200e777c700622993e2eea11b33c4ab6172825df..eee5fcadc1d5a2824cc27c99a778f373add46516 100644 (file)
@@ -1,6 +1,6 @@
 
 /*
- * $Id: acl.cc,v 1.134 1998/02/06 00:48:59 wessels Exp $
+ * $Id: acl.cc,v 1.135 1998/02/06 06:44:31 wessels Exp $
  *
  * DEBUG: section 28    Access Control
  * AUTHOR: Duane Wessels
@@ -2086,11 +2086,37 @@ aclDumpDomainList(void *data)
 #endif
 }
 static wordlist *
-aclDumpTimeSpec(void *data)
-{
-    wordlist *w = xcalloc(1, sizeof(wordlist));
-    w->key = xstrdup("UNIMPLEMENTED");
-    return w;
+aclDumpTimeSpec(acl_time_data *t)
+{
+struct _acl_time_data {
+    int weekbits;
+    int start;
+    int stop;
+    acl_time_data *next;
+};
+    wordlist *W = NULL;
+    wordlist **T = &W;
+    wordlist *w;
+    char buf[128];
+    while (t != NULL) {
+       w = xcalloc(1, sizeof(wordlist));
+       snprintf(buf, 128, "%c%c%c%c%c%c%c %02d:%02d-%02d:%02d",
+               t->weekbits & ACL_SUNDAY ? 'S' : '-',
+               t->weekbits & ACL_MONDAY ? 'M' : '-',
+               t->weekbits & ACL_TUESDAY ? 'T' : '-',
+               t->weekbits & ACL_WEDNESDAY ? 'W' : '-',
+               t->weekbits & ACL_THURSDAY ? 'H' : '-',
+               t->weekbits & ACL_FRIDAY ? 'F' : '-',
+               t->weekbits & ACL_SATURDAY ? 'A' : '-',
+               t->start / 60,
+               t->start % 60,
+               t->stop / 60,
+               t->stop % 60);
+       w->key = xstrdup(buf);
+       *T = w;
+       T = &w->next;
+       t = t->next;
+       
 }
 static wordlist *
 aclDumpRegexList(void *data)
index 39f02bdafbe8de76a8daed4a417920bc778c6fbd..d5d942202d57684cdb75e6db7e4265e5ef844142 100644 (file)
@@ -1982,17 +1982,6 @@ DOC_START
        command line option.
 DOC_END
 
-NAME: snmp_config_file
-TYPE: string
-LOC: Config.Snmp.configFile
-DEFAULT: @DEFAULT_SNMP_CONF@
-IFDEF: SQUID_SNMP
-DOC_START
-       SNMP is configured by a file in the same format as the
-       CMU-snmpd config file. This tag should contain a path to this
-       file.
-DOC_END
-
 NAME: snmp_do_queueing
 TYPE: onoff
 LOC: Config.Snmp.do_queueing
index 8e8c83f64addc7f71f7edfccfcd5598e5454dfe5..98719fdb1385b86b5491dba0d83aa2b02667f6c5 100644 (file)
@@ -1,6 +1,6 @@
 
 /*
- * $Id: squid.h,v 1.156 1998/02/05 20:53:38 wessels Exp $
+ * $Id: squid.h,v 1.157 1998/02/06 06:44:34 wessels Exp $
  *
  * AUTHOR: Duane Wessels
  *
@@ -352,5 +352,6 @@ struct rusage {
 #define free +
 #define calloc +
 #define sprintf +
+#define strdup +
 
 #endif /* SQUID_H */