]> git.ipfire.org Git - thirdparty/squid.git/commitdiff
protect htcp features with USE_HTCP
authorwessels <>
Sun, 29 Mar 1998 01:37:05 +0000 (01:37 +0000)
committerwessels <>
Sun, 29 Mar 1998 01:37:05 +0000 (01:37 +0000)
src/cache_cf.cc
src/enums.h
src/neighbors.cc

index 9c071ab5747c005454b868732f9c895c6e035856..8a3fdc3c8c16f2328291718a8c644fd3318f0680 100644 (file)
@@ -1,6 +1,6 @@
 
 /*
- * $Id: cache_cf.cc,v 1.266 1998/03/28 06:26:42 wessels Exp $
+ * $Id: cache_cf.cc,v 1.267 1998/03/28 18:37:05 wessels Exp $
  *
  * DEBUG: section 3     Configuration File Parsing
  * AUTHOR: Harvest Derived
@@ -698,8 +698,10 @@ parse_peer(peer ** head)
            EBIT_SET(p->options, NEIGHBOR_DEFAULT_PARENT);
        } else if (!strncasecmp(token, "round-robin", 11)) {
            EBIT_SET(p->options, NEIGHBOR_ROUNDROBIN);
+#if USE_HTCP
        } else if (!strncasecmp(token, "htcp", 4)) {
            EBIT_SET(p->options, NEIGHBOR_HTCP);
+#endif
        } else {
            debug(3, 0) ("parse_peer: token='%s'\n", token);
            self_destruct();
index bb77b03d831f14149681afef94da41cd4df0ac49..e1e16cfed3f97c28eaf3ba598a240253fb8d46f9 100644 (file)
@@ -438,7 +438,9 @@ enum {
     NEIGHBOR_ROUNDROBIN,
     NEIGHBOR_MCAST_RESPONDER,
     NEIGHBOR_CLOSEST_ONLY,
+#if USE_HTCP
     NEIGHBOR_HTCP
+#endif
 };
 
 typedef enum {
index dee27758551c864efc561d7367ea289e34f50f50..5f3f9e5ffc3cb2ac83c634bde30dabdce8570ebb 100644 (file)
@@ -1,6 +1,6 @@
 
 /*
- * $Id: neighbors.cc,v 1.185 1998/03/28 06:26:44 wessels Exp $
+ * $Id: neighbors.cc,v 1.186 1998/03/28 18:37:07 wessels Exp $
  *
  * DEBUG: section 15    Neighbor Routines
  * AUTHOR: Harvest Derived
@@ -442,10 +442,13 @@ neighborsUdpPing(request_t * request,
        debug(15, 3) ("neighborsUdpPing: key = '%s'\n", storeKeyText(entry->key));
        debug(15, 3) ("neighborsUdpPing: reqnum = %d\n", reqnum);
 
+#if USE_HTCP
        if (EBIT_TEST(p->options, NEIGHBOR_HTCP)) {
            debug(15, 0)("neighborsUdpPing: sending HTCP query\n");
            htcpQuery(entry, request, p);
-       } else if (p->icp_port == echo_port) {
+       } else
+#endif
+ if (p->icp_port == echo_port) {
            debug(15, 4) ("neighborsUdpPing: Looks like a dumb cache, send DECHO ping\n");
            echo_hdr.reqnum = reqnum;
            query = icpCreateMessage(ICP_DECHO, 0, url, reqnum, 0);
@@ -1005,8 +1008,10 @@ dump_peer_options(StoreEntry * sentry, peer * p)
        storeAppendPrintf(sentry, " multicast-responder");
     if (EBIT_TEST(p->options, NEIGHBOR_CLOSEST_ONLY))
        storeAppendPrintf(sentry, " closest-only");
+#if USE_HTCP
     if (EBIT_TEST(p->options, NEIGHBOR_HTCP))
        storeAppendPrintf(sentry, " htcp");
+#endif
     if (p->mcast.ttl > 0)
        storeAppendPrintf(sentry, " ttl=%d", p->mcast.ttl);
     storeAppendPrintf(sentry, "\n");