--------------------- PatchSet 6215 Date: 2004/04/30 23:33:59 Author: dwsquid Branch: icap-2_5 Tag: (none) Log: The ICAP URI parser in cache_cf.c was too complex and had at least one bug. I've replaced it with a call to urlParse() and added ICAP to the list of known URI methods. Members: src/enums.h:1.29.2.8.2.5->1.29.2.8.2.6 src/url.c:1.7.6.5->1.7.6.5.2.1 Index: squid/src/enums.h =================================================================== RCS file: /cvsroot/squid-sf//squid/src/enums.h,v retrieving revision 1.29.2.8.2.5 retrieving revision 1.29.2.8.2.6 diff -u -r1.29.2.8.2.5 -r1.29.2.8.2.6 --- squid/src/enums.h 2 Mar 2004 07:01:18 -0000 1.29.2.8.2.5 +++ squid/src/enums.h 30 Apr 2004 23:33:59 -0000 1.29.2.8.2.6 @@ -1,6 +1,6 @@ /* - * $Id: enums.h,v 1.29.2.8.2.5 2004/03/02 07:01:18 rhorstmann Exp $ + * $Id: enums.h,v 1.29.2.8.2.6 2004/04/30 23:33:59 dwsquid Exp $ * * * SQUID Web Proxy Cache http://www.squid-cache.org/ @@ -432,6 +432,9 @@ PROTO_WHOIS, PROTO_INTERNAL, PROTO_HTTPS, +#if HS_FEAT_ICAP + PROTO_ICAP, +#endif PROTO_MAX } protocol_t; Index: squid/src/url.c =================================================================== RCS file: /cvsroot/squid-sf//squid/src/url.c,v retrieving revision 1.7.6.5 retrieving revision 1.7.6.5.2.1 diff -u -r1.7.6.5 -r1.7.6.5.2.1 --- squid/src/url.c 19 Jan 2003 03:16:02 -0000 1.7.6.5 +++ squid/src/url.c 30 Apr 2004 23:33:59 -0000 1.7.6.5.2.1 @@ -1,6 +1,6 @@ /* - * $Id: url.c,v 1.7.6.5 2003/01/19 03:16:02 squidadm Exp $ + * $Id: url.c,v 1.7.6.5.2.1 2004/04/30 23:33:59 dwsquid Exp $ * * DEBUG: section 23 URL Parsing * AUTHOR: Duane Wessels @@ -102,6 +102,9 @@ "whois", "internal", "https", +#ifdef HS_FEAT_ICAP + "icap", +#endif "TOTAL" }; @@ -220,6 +223,10 @@ return PROTO_WHOIS; if (strcasecmp(s, "internal") == 0) return PROTO_INTERNAL; +#ifdef HS_FEAT_ICAP + if (strcasecmp(s, "icap") == 0) + return PROTO_ICAP; +#endif return PROTO_NONE; } @@ -243,6 +250,10 @@ return CACHE_HTTP_PORT; case PROTO_WHOIS: return 43; +#ifdef HS_FEAT_ICAP + case PROTO_ICAP: + return 1344; +#endif default: return 0; }