/*
- * $Id: ICP.h,v 1.8 2007/09/21 11:41:52 amosjeffries Exp $
+ * $Id: ICP.h,v 1.9 2007/10/31 04:52:15 amosjeffries Exp $
*
*
* SQUID Web Proxy Cache http://www.squid-cache.org/
* DO NOT add more move fields on pain of breakage.
* DO NOT add virtual methods.
*/
-
struct _icp_common_t
{
unsigned char opcode; /* opcode */
#
# Makefile for the Squid Object Cache server
#
-# $Id: Makefile.am,v 1.192 2007/09/19 08:54:50 hno Exp $
+# $Id: Makefile.am,v 1.193 2007/10/31 04:52:15 amosjeffries Exp $
#
# Uncomment and customize the following to suit your needs:
#
tests/testURL \
@STORE_TESTS@
+### Template for new Unit Test Program
+## - add tests/testX to check_PROGRAMS above.
+## - copy template below and substitue X for class name
+## - add other component .(h|cc) files needed to link and run tests
+##
+##NP: (TESTSOURCES) defines stub debugs() and new/delete for testing
+##
+#tests_testX_SOURCES=\
+# tests/testX.h \
+# tests/testX.cc \
+# tests/testMain.cc \
+# X.h \
+# X.cc \
+# $(TESTSOURCES)
+#tests_testX_LDFLAGS = $(LIBADD_DL)
+#tests_testX_LDADD=\
+# @SQUID_CPPUNIT_LIBS@ \
+# @SQUID_CPPUNIT_LA@ \
+# -L../lib -lmiscutil
+#tests_testX_DEPENDENCIES= @SQUID_CPPUNIT_LA@ \
+# $(top_builddir)/lib/libmiscutil.a
+
tests_testAuth_SOURCES= tests/testAuth.cc tests/testMain.cc tests/testAuth.h $(TESTSOURCES) \
authenticate.cc \
ConfigParser.cc \
-
/*
- * $Id: SquidTime.h,v 1.2 2006/08/12 01:43:11 robertc Exp $
+ * $Id: SquidTime.h,v 1.3 2007/10/31 04:52:16 amosjeffries Exp $
*
* DEBUG: section 21 Time Functions
* AUTHOR: Harvest Derived
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111, USA.
*
*/
-
#ifndef SQUID_TIME_H
#define SQUID_TIME_H
time_t getCurrentTime(void);
-/* event class for doing synthetic time etc */
-
+/** event class for doing synthetic time etc */
class TimeEngine
{
public:
virtual ~TimeEngine();
- /* tick the clock - update from the OS or other time source, */
+
+ /** tick the clock - update from the OS or other time source, */
virtual void tick();
};
-
#endif /* SQUID_TIME_H */
/*
- * $Id: cache_cf.cc,v 1.523 2007/10/22 23:35:32 amosjeffries Exp $
+ * $Id: cache_cf.cc,v 1.524 2007/10/31 04:52:16 amosjeffries Exp $
*
* DEBUG: section 3 Configuration File Parsing
* AUTHOR: Harvest Derived
static void parse_denyinfo(acl_deny_info_list ** var);
static void dump_denyinfo(StoreEntry * entry, const char *name, acl_deny_info_list * var);
static void free_denyinfo(acl_deny_info_list ** var);
+
#if USE_WCCPv2
static void parse_sockaddr_in_list(sockaddr_in_list **);
static void dump_sockaddr_in_list(StoreEntry *, const char *, const sockaddr_in_list *);
#if CURRENTLY_UNUSED
static int check_null_sockaddr_in_list(const sockaddr_in_list *);
#endif /* CURRENTLY_UNUSED */
-#endif
+#endif /* USE_WCCPv2 */
+
static void parse_http_port_list(http_port_list **);
static void dump_http_port_list(StoreEntry *, const char *, const http_port_list *);
static void free_http_port_list(http_port_list **);
+
#if USE_SSL
static void parse_https_port_list(https_port_list **);
static void dump_https_port_list(StoreEntry *, const char *, const https_port_list *);
static int check_null_https_port_list(const https_port_list *);
#endif
#endif /* USE_SSL */
+
static void parse_b_size_t(size_t * var);
static void parse_b_int64_t(int64_t * var);
/*
- * $Id: cache_manager.cc,v 1.47 2007/04/28 22:26:37 hno Exp $
+ * $Id: cache_manager.cc,v 1.48 2007/10/31 04:52:16 amosjeffries Exp $
*
* DEBUG: section 16 Cache Manager Objects
* AUTHOR: Duane Wessels
CacheManagerAction *a;
for (a = ActionTable; a != NULL; a = a->next) {
- storeAppendPrintf(sentry, " %-22s\t%s\t%s\n",
+ storeAppendPrintf(sentry, " %-22s\t%-32s\t%s\n",
a->action, a->desc, cachemgrActionProtection(a));
}
}
-
/*
- * $Id: client_side.h,v 1.25 2007/09/28 00:22:38 hno Exp $
+ * $Id: client_side.h,v 1.26 2007/10/31 04:52:16 amosjeffries Exp $
*
*
* SQUID Web Proxy Cache http://www.squid-cache.org/
bool connRegistered_;
};
-
/* A connection to a socket */
class ConnStateData : public BodyProducer, public RefCountable
{
-
/*
- * $Id: comm.cc,v 1.437 2007/09/25 13:24:59 hno Exp $
+ * $Id: comm.cc,v 1.438 2007/10/31 04:52:16 amosjeffries Exp $
*
* DEBUG: section 5 Socket Functions
* AUTHOR: Harvest Derived
dlinkDelete(&fd_node, &(fdc_table[result.fd].CommCallbackList));
}
-/*
+/**
* add an IO callback
*
* IO callbacks are added when we want to notify someone that some IO
callCallback();
}
-/*
+/**
* call the IO callbacks
*
* This should be called before comm_select() so code can attempt to
return (CommCallbackList.head != NULL) || (commfd_completed_events.head != NULL);
}
-/*
+/**
* Attempt a read
*
* If the read attempt succeeds or fails, call the callback.
commSetSelect(fd, COMM_SELECT_READ, commHandleRead, data, 0);
}
-/*
+/**
* Queue a read. handler/handler_data are called when the read
* completes, on error, or on file descriptor close.
*/
commSetSelect(fd, COMM_SELECT_READ, commHandleRead, COMMIO_FD_READCB(fd), 0);
}
-/*
+/**
* Empty the read buffers
*
* This is a magical routine that empties the read buffers.
assert(fdc_table[fd].active == 1);
}
-/*
+/**
* Return whether the FD has a pending completed callback.
*/
int
return false;
}
-/*
+/**
* return whether a file descriptor has a read handler
*
* Assumptions: the fd is open
return COMMIO_FD_READCB(fd)->active && (! COMMIO_FD_READCB(fd)->completed);
}
-/*
+/**
* Cancel a pending read. Assert that we have the right parameters,
* and that there are no pending read events!
*
}
-/*
+/**
* Open a filedescriptor, set some sane defaults
* XXX DPW 2006-05-30 what is the point of this?
*/
}
-/*
+/**
* synchronous wrapper around udp socket functions
*/
-
int
comm_udp_recvfrom(int fd, void *buf, size_t len, int flags,
-
struct sockaddr *from, socklen_t *fromlen)
{
statCounter.syscalls.sock.recvfroms++;
return COMMIO_FD_WRITECB(fd)->active;
}
-/*
+/**
* Queue a write. handler/handler_data are called when the write fully
* completes, on error, or on file descriptor close.
*/
}
static comm_err_t
-
commBind(int s, struct IN_ADDR in_addr, u_short port)
{
-
struct sockaddr_in S;
memset(&S, '\0', sizeof(S));
return COMM_ERROR;
}
-/* Create a socket. Default is blocking, stream (TCP) socket. IO_TYPE
- * is OR of flags specified in comm.h. Defaults TOS */
+/**
+ * Create a socket. Default is blocking, stream (TCP) socket. IO_TYPE
+ * is OR of flags specified in comm.h. Defaults TOS
+ */
int
comm_open(int sock_type,
int proto,
-
struct IN_ADDR addr,
u_short port,
int flags,
debugs(50, 1, "comm_set_tos: setsockopt(IP_TOS) on FD " << fd << ": " << xstrerror());
return x;
#else
- debugs(50, 0, "comm_set_tos: setsockopt(IP_TOS) not supported on this platform");
+ debugs(50, 0, "WARNING: setsockopt(IP_TOS) not supported on this platform");
return -1;
#endif
}
-/* Create a socket. Default is blocking, stream (TCP) socket. IO_TYPE
- * is OR of flags specified in defines.h:COMM_* */
+/**
+ * Create a socket. Default is blocking, stream (TCP) socket. IO_TYPE
+ * is OR of flags specified in defines.h:COMM_*
+ */
int
comm_openex(int sock_type,
int proto,
-
struct IN_ADDR addr,
u_short port,
int flags,
-
/*
- * $Id: debug.cc,v 1.103 2007/08/01 23:04:23 amosjeffries Exp $
+ * $Id: debug.cc,v 1.104 2007/10/31 04:52:16 amosjeffries Exp $
*
* DEBUG: section 0 Debug Routines
* AUTHOR: Harvest Derived