/*
- * $Id: acl.cc,v 1.71 1996/12/20 23:45:35 wessels Exp $
+ * $Id: acl.cc,v 1.72 1997/01/10 18:48:42 wessels Exp $
*
* DEBUG: section 28 Access Control
* AUTHOR: Duane Wessels
memset(addr2, 0, 256);
memset(mask, 0, 256);
-#ifdef OLD_CODE
- /* This breaks on "www-cache.uninett.no" because of the dash */
- /* Split the adress in addr1-addr2/mask */
- strncpy(addr1, p, strcspn(p, "-/"));
- p += strcspn(p, "-/");
- if (*p == '-') {
- p++;
- strncpy(addr2, p, strcspn(p, "/"));
- p += strcspn(p, "/");
- }
- if (*p == '/') {
- p++;
- strcpy(mask, p);
- }
-#endif
-#ifndef NEW_CODE
for (;;) {
if (sscanf(t, "%[0-9.]-%[0-9.]/%[0-9.]", addr1, addr2, mask) == 3)
break;
debug(28, 0, "aclParseIpList: Bad host/IP: '%s'\n", t);
break;
}
-#endif
+
/* Decode addr1 */
if (!decode_addr(addr1, &q->addr1, &q->mask)) {
debug(28, 0, "%s line %d: %s\n",