diff -u -r -N squid-3.2.0.14/ChangeLog squid-3.2.0.15/ChangeLog
--- squid-3.2.0.14/ChangeLog	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/ChangeLog	2012-02-06 04:52:31.000000000 +1300
@@ -1,3 +1,24 @@
+Changes to squid-3.2.0.15 (06 Feb 2011):
+
+	- Bug 3472: segfault with the message 'urlParse: URL too large'
+	- Bug 3471: segfault when %la formating code used
+	- Bug 3449: part 3: shm_open can fail with a mangled path
+	- Bug 3449: part 4: shm_open failed (fixing memory_cache_shared defaults)
+	- Bug 3448: 204 response problem in adaptation chains
+	- Bug 3447: assertion failed: CommCalls.h:150: "dp"
+	- Bug 3461: build regression in IPFilter NAT
+	- Bug 3413: raise cbdata lock limits
+	- Bug 3391: forwarded_for log functionality broken
+	- Bug 3268: Squid cannot do anything else during ufs/diskd rebuild
+	- Bug 3268: remove wrong 'Ready to serve requests.' message
+	- Bug 2519: ssl_bump + Authentication (LDAP Digest) issues
+	- Disable OpenSSL SSL/TLS bug workarounds by default
+	- Send DNS A and AAAA queries in parallel
+	- Cache Manager migration support
+	- Allow service of internal requests over reverse-proxy ports
+	- Fix trimMemory for unswappable objects
+	- ... and several build and polish fixes
+
 Changes to squid-3.2.0.14 (12 Dec 2011):
 
 	- Bug 3433: Segfault closing SNMP
@@ -312,6 +333,20 @@
 	- ... and a great many testing improvements
 	- ... and many documentation updates
 
+Changes to squid-3.1.19 (06 Feb 2011):
+
+	- Regression Bug 3441: part 2: Prevent further cache size corruption of swap.state
+	- Bug 3473: erase last uses of obsolete auth_user_hash_pointer
+	- Bug 3470: GCC 4.7
+	- Bug 3442: assertion failed: external_acl.cc:908: ch->auth_user_request != NULL
+	- Bug 3441: part 1: Minimize cache size corruption by malformed swap.state
+	- Bug 3440: compile error in Adaptation
+	- Bug 3420: Request body consumption races and !theConsumer exception
+	- Bug 3370: external ACL sometimes skipping
+	- Bug 3085: Crash when parsing esi:include
+	- HTTP/1.1: do not add 110 and 111 Warnings to revalidated responses
+	- Fix SSL library dependency fixes
+
 Changes to squid-3.1.18 (03 Dec 2011):
 
 	- Regression: compile error in FTP
diff -u -r -N squid-3.2.0.14/compat/assert.cc squid-3.2.0.15/compat/assert.cc
--- squid-3.2.0.14/compat/assert.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/compat/assert.cc	2012-02-06 04:52:31.000000000 +1300
@@ -31,7 +31,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 
 void xassert(const char *expr, const char *file, int line)
 {
diff -u -r -N squid-3.2.0.14/compat/compat.cc squid-3.2.0.15/compat/compat.cc
--- squid-3.2.0.14/compat/compat.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/compat/compat.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "config.h"
+#include "squid.h"
 #include "compat.h"
 
 void (*failure_notify) (const char *) = NULL;
diff -u -r -N squid-3.2.0.14/compat/compat.h squid-3.2.0.15/compat/compat.h
--- squid-3.2.0.14/compat/compat.h	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/compat/compat.h	2012-02-06 04:52:31.000000000 +1300
@@ -8,11 +8,11 @@
  *
  * This file is meant to collate all those hacks files together and
  * provide a simple include for them in the core squid headers
- * (presently squid.h and config.h)
+ * (presently squid.h)
  *
  * It should not be included directly in any of the squid sources.
  * If your code requires any symbols from here you should be importing
- * config.h/squid.h at the top line of your .cc or .h file.
+ * squid.h at the top line of your .cc file.
  */
 
 
diff -u -r -N squid-3.2.0.14/compat/debug.cc squid-3.2.0.15/compat/debug.cc
--- squid-3.2.0.14/compat/debug.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/compat/debug.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "config.h"
+#include "squid.h"
 #include "compat/debug.h"
 
 /* default off */
diff -u -r -N squid-3.2.0.14/compat/drand48.c squid-3.2.0.15/compat/drand48.c
--- squid-3.2.0.14/compat/drand48.c	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/compat/drand48.c	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "config.h"
+#include "squid.h"
 
 /* borrowed from libc/misc/drand48.c in Linux libc-5.4.46 this quick
  * hack by Martin Hamilton <martinh@gnu.org> to make Squid build on
diff -u -r -N squid-3.2.0.14/compat/eui64_aton.c squid-3.2.0.15/compat/eui64_aton.c
--- squid-3.2.0.14/compat/eui64_aton.c	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/compat/eui64_aton.c	2012-02-06 04:52:31.000000000 +1300
@@ -74,7 +74,7 @@
  * Columbia University, New York City
  */
 
-#include "config.h"
+#include "squid.h"
 #include "compat/eui64_aton.h"
 
 /*
diff -u -r -N squid-3.2.0.14/compat/fdsetsize.h squid-3.2.0.15/compat/fdsetsize.h
--- squid-3.2.0.14/compat/fdsetsize.h	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/compat/fdsetsize.h	2012-02-06 04:52:31.000000000 +1300
@@ -15,7 +15,7 @@
 */
 #ifdef _SYS_TYPES_H
 #error squid_fdsetsize.h for FDSETSIZE must be included before sys/types.h
-#error Make sure that squid.h or config.h is the first file included by your .cc
+#error Make sure that squid.h is the first file included by your .cc
 #endif
 #endif /* 0 */
 /*
diff -u -r -N squid-3.2.0.14/compat/getaddrinfo.c squid-3.2.0.15/compat/getaddrinfo.c
--- squid-3.2.0.14/compat/getaddrinfo.c	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/compat/getaddrinfo.c	2012-02-06 04:52:31.000000000 +1300
@@ -16,7 +16,7 @@
  *
  *  Original License and code follows.
  */
-#include "config.h"
+#include "squid.h"
 
 /*
  *  This file is part of libESMTP, a library for submission of RFC 2822
diff -u -r -N squid-3.2.0.14/compat/getnameinfo.c squid-3.2.0.15/compat/getnameinfo.c
--- squid-3.2.0.14/compat/getnameinfo.c	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/compat/getnameinfo.c	2012-02-06 04:52:31.000000000 +1300
@@ -18,7 +18,7 @@
  *
  *  Original License and code follows.
  */
-#include "config.h"
+#include "squid.h"
 
 /*	KAME: getnameinfo.c,v 1.72 2005/01/13 04:12:03 itojun Exp 	*/
 
diff -u -r -N squid-3.2.0.14/compat/GnuRegex.c squid-3.2.0.15/compat/GnuRegex.c
--- squid-3.2.0.14/compat/GnuRegex.c	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/compat/GnuRegex.c	2012-02-06 04:52:31.000000000 +1300
@@ -32,7 +32,7 @@
 #define _GNU_SOURCE 1
 #endif
 
-#include "config.h"
+#include "squid.h"
 
 #if USE_GNUREGEX /* only if squid needs it. Usually not */
 
diff -u -r -N squid-3.2.0.14/compat/inet_ntop.c squid-3.2.0.15/compat/inet_ntop.c
--- squid-3.2.0.14/compat/inet_ntop.c	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/compat/inet_ntop.c	2012-02-06 04:52:31.000000000 +1300
@@ -21,7 +21,7 @@
  *  Original License and code follows.
  */
 
-#include "config.h"
+#include "squid.h"
 
 #if !HAVE_INET_NTOP
 #include "inet_ntop.h"
diff -u -r -N squid-3.2.0.14/compat/inet_pton.c squid-3.2.0.15/compat/inet_pton.c
--- squid-3.2.0.14/compat/inet_pton.c	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/compat/inet_pton.c	2012-02-06 04:52:31.000000000 +1300
@@ -18,7 +18,7 @@
  *  Original License and code follows.
  */
 
-#include "config.h"
+#include "squid.h"
 
 #if !HAVE_INET_PTON
 
diff -u -r -N squid-3.2.0.14/compat/initgroups.c squid-3.2.0.15/compat/initgroups.c
--- squid-3.2.0.14/compat/initgroups.c	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/compat/initgroups.c	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "config.h"
+#include "squid.h"
 #include "compat/initgroups.h"
 
 #if HAVE_GRP_H
diff -u -r -N squid-3.2.0.14/compat/mswin.cc squid-3.2.0.15/compat/mswin.cc
--- squid-3.2.0.14/compat/mswin.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/compat/mswin.cc	2012-02-06 04:52:31.000000000 +1300
@@ -34,7 +34,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 #include "util.h"
 
 /* The following code section is part of an EXPERIMENTAL native */
diff -u -r -N squid-3.2.0.14/compat/psignal.c squid-3.2.0.15/compat/psignal.c
--- squid-3.2.0.14/compat/psignal.c	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/compat/psignal.c	2012-02-06 04:52:31.000000000 +1300
@@ -2,7 +2,7 @@
  * Author:   Jens-S. V?ckler <voeckler@rvs.uni-hannover.de>
  * Ripped from Purge tool implementation.
  */
-#include "config.h"
+#include "squid.h"
 #include "psignal.h"
 
 #if _SQUID_AIX_ || _SQUID_MINGW_
diff -u -r -N squid-3.2.0.14/compat/shm.cc squid-3.2.0.15/compat/shm.cc
--- squid-3.2.0.14/compat/shm.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/compat/shm.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "config.h"
+#include "squid.h"
 #include "compat/shm.h"
 
 #if _SQUID_FREEBSD_ && (__FreeBSD__ >= 7)
diff -u -r -N squid-3.2.0.14/compat/strerror.c squid-3.2.0.15/compat/strerror.c
--- squid-3.2.0.14/compat/strerror.c	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/compat/strerror.c	2012-02-06 04:52:31.000000000 +1300
@@ -32,7 +32,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 
 #if HAVE_ERRNO_H
 #include <errno.h>
diff -u -r -N squid-3.2.0.14/compat/strnrchr.c squid-3.2.0.15/compat/strnrchr.c
--- squid-3.2.0.14/compat/strnrchr.c	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/compat/strnrchr.c	2012-02-06 04:52:31.000000000 +1300
@@ -28,7 +28,7 @@
  *  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111, USA.
  */
 
-#include "config.h"
+#include "squid.h"
 #include "strnrchr.h"
 
 const char *
diff -u -r -N squid-3.2.0.14/compat/strnstr.cc squid-3.2.0.15/compat/strnstr.cc
--- squid-3.2.0.14/compat/strnstr.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/compat/strnstr.cc	2012-02-06 04:52:31.000000000 +1300
@@ -17,7 +17,7 @@
  *  Original License and code follows.
  */
 
-#include "config.h"
+#include "squid.h"
 
 #if !HAVE_STRNSTR
 
diff -u -r -N squid-3.2.0.14/compat/strsep.c squid-3.2.0.15/compat/strsep.c
--- squid-3.2.0.14/compat/strsep.c	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/compat/strsep.c	2012-02-06 04:52:31.000000000 +1300
@@ -17,7 +17,7 @@
  * USA.
  */
 
-#include "config.h"
+#include "squid.h"
 #include "compat/strsep.h"
 
 #include <string.h>
diff -u -r -N squid-3.2.0.14/compat/strtoll.c squid-3.2.0.15/compat/strtoll.c
--- squid-3.2.0.14/compat/strtoll.c	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/compat/strtoll.c	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
 
 /* modified for long long <mgd@swarm.org> 1999-08-12 */
 
-#include "config.h"
+#include "squid.h"
 #include "compat/strtoll.h"
 
 #if HAVE_CTYPE_H
diff -u -r -N squid-3.2.0.14/compat/tempnam.c squid-3.2.0.15/compat/tempnam.c
--- squid-3.2.0.14/compat/tempnam.c	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/compat/tempnam.c	2012-02-06 04:52:31.000000000 +1300
@@ -8,7 +8,7 @@
  * temp file is written in /tmp.
  */
 
-#include "config.h"
+#include "squid.h"
 #include "compat/tempnam.h"
 
 #if HAVE_LIBC_H
diff -u -r -N squid-3.2.0.14/compat/testPreCompiler.cc squid-3.2.0.15/compat/testPreCompiler.cc
--- squid-3.2.0.14/compat/testPreCompiler.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/compat/testPreCompiler.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,5 +1,5 @@
 #define SQUID_UNIT_TEST 1
-#include "config.h"
+#include "squid.h"
 
 #if HAVE_ASSERT_H
 #include <assert.h>
diff -u -r -N squid-3.2.0.14/compat/xalloc.cc squid-3.2.0.15/compat/xalloc.cc
--- squid-3.2.0.14/compat/xalloc.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/compat/xalloc.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "config.h"
+#include "squid.h"
 #include "compat/xalloc.h"
 #include "profiler/Profiler.h"
 
@@ -194,15 +194,6 @@
 }
 
 void
-xfree(void *s)
-{
-    if (s == NULL)
-        return;
-
-    free_const(s);
-}
-
-void
 free_const(const void *s_const)
 {
     void *s = const_cast<void *>(s_const);
diff -u -r -N squid-3.2.0.14/compat/xalloc.h squid-3.2.0.15/compat/xalloc.h
--- squid-3.2.0.14/compat/xalloc.h	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/compat/xalloc.h	2012-02-06 04:52:31.000000000 +1300
@@ -30,27 +30,29 @@
     void *xrealloc(void *s, size_t sz);
 
     /**
-     *  xfree() - same as free(3).  Used for portability.
-     *   Will not call free(3) if s == NULL.
+     * free_const() - Same as free(3).  Used for portability.
+     * Accepts pointers to dynamically allocated const data.
      *
      * Define failure_notify to receive error message.
      * otherwise perror() is used to display it.
      */
-    void xfree(void *s);
+    void free_const(const void *s);
 
     /**
-     * xxfree() / free_const() - Same as free(3).  Used for portability.
+     *  xfree() - same as free(3).  Used for portability.
      * Accepts pointers to dynamically allocated const data.
+     * Will not call free(3) if the pointer is NULL.
+     *
+     * Pointer is left with a value on completion.
+     * Use safe_free() if the pointer needs to be set to NULL afterward.
      *
      * Define failure_notify to receive error message.
      * otherwise perror() is used to display it.
      */
-    void free_const(const void *s);
-
-/// Backward compatibility alias for free_const(const void *s)
-#define xxfree(x)  free_const((x))
+    static inline void xfree(const void *p) { if (p) free_const(p); }
 
     /**
+     *  safe_free() - same as free(3).  Used for portability.
      * Accepts pointers to dynamically allocated const data.
      * Will not call free(3) if the pointer is NULL.
      * Sets the pointer to NULL on completion.
@@ -60,7 +62,7 @@
      * Define failure_notify to receive error message.
      * otherwise perror() is used to display it.
      */
-#define safe_free(x)    while (x) { xxfree(x); (x) = NULL; }
+#define safe_free(x)    while ((x)) { free_const((x)); (x) = NULL; }
 
 #ifdef __cplusplus
 }
diff -u -r -N squid-3.2.0.14/compat/xstrerror.cc squid-3.2.0.15/compat/xstrerror.cc
--- squid-3.2.0.14/compat/xstrerror.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/compat/xstrerror.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "config.h"
+#include "squid.h"
 #include "compat/xstrerror.h"
 
 #if HAVE_STRING_H
diff -u -r -N squid-3.2.0.14/compat/xstring.cc squid-3.2.0.15/compat/xstring.cc
--- squid-3.2.0.14/compat/xstring.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/compat/xstring.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "config.h"
+#include "squid.h"
 #include "compat/xalloc.h"
 #include "compat/xstring.h"
 
diff -u -r -N squid-3.2.0.14/compat/xstrto.cc squid-3.2.0.15/compat/xstrto.cc
--- squid-3.2.0.14/compat/xstrto.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/compat/xstrto.cc	2012-02-06 04:52:31.000000000 +1300
@@ -28,7 +28,7 @@
  *  Original License and code follows.
  */
 
-#include "config.h"
+#include "squid.h"
 #include "compat/xstrto.h"
 
 /*
diff -u -r -N squid-3.2.0.14/configure squid-3.2.0.15/configure
--- squid-3.2.0.14/configure	2011-12-13 00:11:47.000000000 +1300
+++ squid-3.2.0.15/configure	2012-02-06 05:01:03.000000000 +1300
@@ -1,7 +1,7 @@
 #! /bin/sh
 # From configure.ac Revision.
 # Guess values for system-dependent variables and create Makefiles.
-# Generated by GNU Autoconf 2.68 for Squid Web Proxy 3.2.0.14.
+# Generated by GNU Autoconf 2.68 for Squid Web Proxy 3.2.0.15.
 #
 # Report bugs to <http://www.squid-cache.org/bugs/>.
 #
@@ -575,8 +575,8 @@
 # Identity of this package.
 PACKAGE_NAME='Squid Web Proxy'
 PACKAGE_TARNAME='squid'
-PACKAGE_VERSION='3.2.0.14'
-PACKAGE_STRING='Squid Web Proxy 3.2.0.14'
+PACKAGE_VERSION='3.2.0.15'
+PACKAGE_STRING='Squid Web Proxy 3.2.0.15'
 PACKAGE_BUGREPORT='http://www.squid-cache.org/bugs/'
 PACKAGE_URL=''
 
@@ -684,8 +684,8 @@
 DEFAULT_HOSTS
 USE_SSL_CRTD_FALSE
 USE_SSL_CRTD_TRUE
-USE_DNSSERVER_FALSE
-USE_DNSSERVER_TRUE
+ENABLE_DNSHELPER_FALSE
+ENABLE_DNSHELPER_TRUE
 MAKE_LEAKFINDER_FALSE
 MAKE_LEAKFINDER_TRUE
 EPOLL_LIBS
@@ -1570,7 +1570,7 @@
   # Omit some internal or obsolete options to make the list less imposing.
   # This message is too long to be a string in the A/UX 3.1 sh.
   cat <<_ACEOF
-\`configure' configures Squid Web Proxy 3.2.0.14 to adapt to many kinds of systems.
+\`configure' configures Squid Web Proxy 3.2.0.15 to adapt to many kinds of systems.
 
 Usage: $0 [OPTION]... [VAR=VALUE]...
 
@@ -1640,7 +1640,7 @@
 
 if test -n "$ac_init_help"; then
   case $ac_init_help in
-     short | recursive ) echo "Configuration of Squid Web Proxy 3.2.0.14:";;
+     short | recursive ) echo "Configuration of Squid Web Proxy 3.2.0.15:";;
    esac
   cat <<\_ACEOF
 
@@ -2018,7 +2018,7 @@
 test -n "$ac_init_help" && exit $ac_status
 if $ac_init_version; then
   cat <<\_ACEOF
-Squid Web Proxy configure 3.2.0.14
+Squid Web Proxy configure 3.2.0.15
 generated by GNU Autoconf 2.68
 
 Copyright (C) 2010 Free Software Foundation, Inc.
@@ -3114,7 +3114,7 @@
 This file contains any messages produced by compilers while
 running configure, to aid debugging if configure makes a mistake.
 
-It was created by Squid Web Proxy $as_me 3.2.0.14, which was
+It was created by Squid Web Proxy $as_me 3.2.0.15, which was
 generated by GNU Autoconf 2.68.  Invocation command line was
 
   $ $0 $@
@@ -3933,7 +3933,7 @@
 
 # Define the identity of the package.
  PACKAGE='squid'
- VERSION='3.2.0.14'
+ VERSION='3.2.0.15'
 
 
 cat >>confdefs.h <<_ACEOF
@@ -21508,38 +21508,38 @@
 unset squid_tmp_define
 
 
-squid_opt_use_dnsserver="no"
+squid_opt_use_dnshelper="no"
 # Check whether --enable-internal-dns was given.
 if test "${enable_internal_dns+set}" = set; then :
   enableval=$enable_internal_dns;
   if test "x$enableval" = "xno" ; then
     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Disabling Internal DNS queries" >&5
 $as_echo "$as_me: WARNING: Disabling Internal DNS queries" >&2;}
-    squid_opt_use_dnsserver="yes"
+    squid_opt_use_dnshelper="yes"
   fi
 
 fi
 
 
 squid_tmp_define=""
-case "$squid_opt_use_dnsserver" in
+case "$squid_opt_use_dnshelper" in
   yes|true|1) squid_tmp_define="1" ;;
   no|false|0|"") squid_tmp_define="0" ;;
-  *) as_fn_error $? "SQUID_DEFINE_BOOL: unrecognized value for USE_DNSSERVERS: '$squid_opt_use_dnsserver'" "$LINENO" 5 ;;
+  *) as_fn_error $? "SQUID_DEFINE_BOOL: unrecognized value for USE_DNSHELPER: '$squid_opt_use_dnshelper'" "$LINENO" 5 ;;
 esac
 
 cat >>confdefs.h <<_ACEOF
-#define USE_DNSSERVERS $squid_tmp_define
+#define USE_DNSHELPER $squid_tmp_define
 _ACEOF
 
 unset squid_tmp_define
 
- if test "x$squid_opt_use_dnsserver" = "xyes" ; then
-  USE_DNSSERVER_TRUE=
-  USE_DNSSERVER_FALSE='#'
+ if test "x$squid_opt_use_dnshelper" = "xyes" ; then
+  ENABLE_DNSHELPER_TRUE=
+  ENABLE_DNSHELPER_FALSE='#'
 else
-  USE_DNSSERVER_TRUE='#'
-  USE_DNSSERVER_FALSE=
+  ENABLE_DNSHELPER_TRUE='#'
+  ENABLE_DNSHELPER_FALSE=
 fi
 
 
@@ -29323,7 +29323,7 @@
     conftest$ac_exeext conftest.$ac_ext
 
 
-if test "x$squid_opt_use_dnsserver" = "xyes"; then
+if test "x$squid_opt_use_dnshelper" = "xyes"; then
 
   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libresolv _dns_ttl_ hack" >&5
 $as_echo_n "checking for libresolv _dns_ttl_ hack... " >&6; }
@@ -30154,8 +30154,8 @@
   as_fn_error $? "conditional \"MAKE_LEAKFINDER\" was never defined.
 Usually this means the macro was only invoked conditionally." "$LINENO" 5
 fi
-if test -z "${USE_DNSSERVER_TRUE}" && test -z "${USE_DNSSERVER_FALSE}"; then
-  as_fn_error $? "conditional \"USE_DNSSERVER\" was never defined.
+if test -z "${ENABLE_DNSHELPER_TRUE}" && test -z "${ENABLE_DNSHELPER_FALSE}"; then
+  as_fn_error $? "conditional \"ENABLE_DNSHELPER\" was never defined.
 Usually this means the macro was only invoked conditionally." "$LINENO" 5
 fi
 if test -z "${USE_SSL_CRTD_TRUE}" && test -z "${USE_SSL_CRTD_FALSE}"; then
@@ -30632,7 +30632,7 @@
 # report actual input values of CONFIG_FILES etc. instead of their
 # values after options handling.
 ac_log="
-This file was extended by Squid Web Proxy $as_me 3.2.0.14, which was
+This file was extended by Squid Web Proxy $as_me 3.2.0.15, which was
 generated by GNU Autoconf 2.68.  Invocation command line was
 
   CONFIG_FILES    = $CONFIG_FILES
@@ -30698,7 +30698,7 @@
 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
 ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
 ac_cs_version="\\
-Squid Web Proxy config.status 3.2.0.14
+Squid Web Proxy config.status 3.2.0.15
 configured by $0, generated by GNU Autoconf 2.68,
   with options \\"\$ac_cs_config\\"
 
diff -u -r -N squid-3.2.0.14/configure.ac squid-3.2.0.15/configure.ac
--- squid-3.2.0.14/configure.ac	2011-12-13 00:11:46.000000000 +1300
+++ squid-3.2.0.15/configure.ac	2012-02-06 05:00:59.000000000 +1300
@@ -3,7 +3,7 @@
 dnl
 dnl
 dnl
-AC_INIT([Squid Web Proxy],[3.2.0.14],[http://www.squid-cache.org/bugs/],[squid])
+AC_INIT([Squid Web Proxy],[3.2.0.15],[http://www.squid-cache.org/bugs/],[squid])
 AC_PREREQ(2.61)
 AC_CONFIG_HEADERS([include/autoconf.h])
 AC_CONFIG_AUX_DIR(cfgaux)
@@ -1578,19 +1578,19 @@
 AC_MSG_NOTICE([Support for Ident lookups enabled: ${enable_ident_lookups:=yes}])
 SQUID_DEFINE_BOOL(USE_IDENT,$enable_ident_lookups,[Support for Ident (RFC 931) lookups])
 
-squid_opt_use_dnsserver="no"
+squid_opt_use_dnshelper="no"
 AC_ARG_ENABLE(internal-dns,
   AS_HELP_STRING([--disable-internal-dns],
            [Prevents Squid from directly sending and receiving DNS messages, 
             and instead enables the old external 'dnsserver' processes.]), [
   if test "x$enableval" = "xno" ; then
     AC_MSG_WARN([Disabling Internal DNS queries])
-    squid_opt_use_dnsserver="yes"
+    squid_opt_use_dnshelper="yes"
   fi
 ])
-SQUID_DEFINE_BOOL(USE_DNSSERVERS,$squid_opt_use_dnsserver,
+SQUID_DEFINE_BOOL(USE_DNSHELPER,$squid_opt_use_dnshelper,
   [Use dnsserver processes instead of the internal DNS protocol support])
-AM_CONDITIONAL([USE_DNSSERVER],[test "x$squid_opt_use_dnsserver" = "xyes" ])
+AM_CONDITIONAL([ENABLE_DNSHELPER],[test "x$squid_opt_use_dnshelper" = "xyes" ])
 
 
 AM_CONDITIONAL(USE_SSL_CRTD, false)
@@ -3368,7 +3368,7 @@
 SQUID_CHECK_NEED_SYS_ERRLIST
 SQUID_CHECK_MAXPATHLEN
 
-if test "x$squid_opt_use_dnsserver" = "xyes"; then
+if test "x$squid_opt_use_dnshelper" = "xyes"; then
   SQUID_CHECK_LIBRESOLV_DNS_TTL_HACK
   SQUID_CHECK_RESOLVER_FIELDS
 fi
diff -u -r -N squid-3.2.0.14/contrib/rredir.c squid-3.2.0.15/contrib/rredir.c
--- squid-3.2.0.14/contrib/rredir.c	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/contrib/rredir.c	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "config.h"
+#include "squid.h"
 
 /*
  * From:    richard@hekkihek.hacom.nl (Richard Huveneers)
diff -u -r -N squid-3.2.0.14/errors/af/ERR_CONFLICT_HOST squid-3.2.0.15/errors/af/ERR_CONFLICT_HOST
--- squid-3.2.0.14/errors/af/ERR_CONFLICT_HOST	1970-01-01 12:00:00.000000000 +1200
+++ squid-3.2.0.15/errors/af/ERR_CONFLICT_HOST	2012-02-06 05:09:45.000000000 +1300
@@ -0,0 +1 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html><head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8"> <title>FOUT: Die aangevraagde URL kon nie verkry word nie</title> <style type="text/css"><!--   %l  body :lang(fa) { direction: rtl; font-size: 100%; font-family: Tahoma, Roya, sans-serif; float: right; } :lang(he) { direction: rtl; }  --></style> </head><body id=%c> <div id="titles"> <h1>ERROR</h1> <h2>The requested URL could not be retrieved</h2> </div> <hr>  <div id="content"> <p>Die volgende fout is teëgekom tydens verkryging van die URL: <a href="%U">%U</a></p>  <blockquote id="data"> <pre>URI Host Conflict</pre> </blockquote>  <p>This means the domain name you are trying to access apparently no longer exists on the machine you are requesting it from.</p>  <p>Enkele moontlike probleme is:</p> <ul> <li>The domain may have moved very recently. Trying again will resolve that.</li> <li>The website may require you to use a local country-based version. Using your ISP provided DNS server(s) should resolve that.</li> </ul>  <p>Die kasbediener se administrateur is <a href="mailto:%w%W">%w</a>.</p> <br> </div>  <hr> <div id="footer"> <p>Gegenereer op %T deur %h (%s)</p> <!-- %c --> </div> </body></html> 
\ No newline at end of file
diff -u -r -N squid-3.2.0.14/errors/ar/ERR_CONFLICT_HOST squid-3.2.0.15/errors/ar/ERR_CONFLICT_HOST
--- squid-3.2.0.14/errors/ar/ERR_CONFLICT_HOST	1970-01-01 12:00:00.000000000 +1200
+++ squid-3.2.0.15/errors/ar/ERR_CONFLICT_HOST	2012-02-06 05:11:20.000000000 +1300
@@ -0,0 +1 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html><head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8"> <title>خطأ: The requested URL could not be retrieved</title> <style type="text/css"><!--   %l  body :lang(fa) { direction: rtl; font-size: 100%; font-family: Tahoma, Roya, sans-serif; float: right; } :lang(he) { direction: rtl; }  --></style> </head><body id=%c> <div id="titles"> <h1>ERROR</h1> <h2>The requested URL could not be retrieved</h2> </div> <hr>  <div id="content"> <p>The following error was encountered while trying to retrieve the URL: <a href="%U">%U</a></p>  <blockquote id="data"> <pre>URI Host Conflict</pre> </blockquote>  <p>This means the domain name you are trying to access apparently no longer exists on the machine you are requesting it from.</p>  <p>Some possible problems are:</p> <ul> <li>The domain may have moved very recently. Trying again will resolve that.</li> <li>The website may require you to use a local country-based version. Using your ISP provided DNS server(s) should resolve that.</li> </ul>  <p>Your cache administrator is <a href="mailto:%w%W">%w</a>.</p> <br> </div>  <hr> <div id="footer"> <p>Generated %T by %h (%s)</p> <!-- %c --> </div> </body></html> 
\ No newline at end of file
diff -u -r -N squid-3.2.0.14/errors/az/ERR_CONFLICT_HOST squid-3.2.0.15/errors/az/ERR_CONFLICT_HOST
--- squid-3.2.0.14/errors/az/ERR_CONFLICT_HOST	1970-01-01 12:00:00.000000000 +1200
+++ squid-3.2.0.15/errors/az/ERR_CONFLICT_HOST	2012-02-06 05:12:43.000000000 +1300
@@ -0,0 +1 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html><head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8"> <title>SƏHV: Sorğulanan URL ilə əlaqə yaradılmadı</title> <style type="text/css"><!--   %l  body :lang(fa) { direction: rtl; font-size: 100%; font-family: Tahoma, Roya, sans-serif; float: right; } :lang(he) { direction: rtl; }  --></style> </head><body id=%c> <div id="titles"> <h1>ERROR</h1> <h2>The requested URL could not be retrieved</h2> </div> <hr>  <div id="content"> <p>The following error was encountered while trying to retrieve the URL: <a href="%U">%U</a></p>  <blockquote id="data"> <pre>URI Host Conflict</pre> </blockquote>  <p>This means the domain name you are trying to access apparently no longer exists on the machine you are requesting it from.</p>  <p>Mümkün probleml�^�rd�^�n b�^�zil�^�ri:</p> <ul> <li>The domain may have moved very recently. Trying again will resolve that.</li> <li>The website may require you to use a local country-based version. Using your ISP provided DNS server(s) should resolve that.</li> </ul>  <p>Your cache administrator is <a href="mailto:%w%W">%w</a>.</p> <br> </div>  <hr> <div id="footer"> <p>Generated %T by %h (%s)</p> <!-- %c --> </div> </body></html> 
\ No newline at end of file
diff -u -r -N squid-3.2.0.14/errors/bg/ERR_CONFLICT_HOST squid-3.2.0.15/errors/bg/ERR_CONFLICT_HOST
--- squid-3.2.0.14/errors/bg/ERR_CONFLICT_HOST	1970-01-01 12:00:00.000000000 +1200
+++ squid-3.2.0.15/errors/bg/ERR_CONFLICT_HOST	2012-02-06 05:14:12.000000000 +1300
@@ -0,0 +1 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html><head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8"> <title>ГРЕШКА: Заявеният адрес е недостъпен.</title> <style type="text/css"><!--   %l  body :lang(fa) { direction: rtl; font-size: 100%; font-family: Tahoma, Roya, sans-serif; float: right; } :lang(he) { direction: rtl; }  --></style> </head><body id=%c> <div id="titles"> <h1>ERROR</h1> <h2>The requested URL could not be retrieved</h2> </div> <hr>  <div id="content"> <p>Възникна следната грешка при опит за достъп до: <a href="%U">%U</a></p>  <blockquote id="data"> <pre>URI Host Conflict</pre> </blockquote>  <p>This means the domain name you are trying to access apparently no longer exists on the machine you are requesting it from.</p>  <p>Възможни грешки:</p> <ul> <li>The domain may have moved very recently. Trying again will resolve that.</li> <li>The website may require you to use a local country-based version. Using your ISP provided DNS server(s) should resolve that.</li> </ul>  <p>Вашият кеш администратор е <a href="mailto:%w%W">%w</a>.</p> <br> </div>  <hr> <div id="footer"> <p>Генерирано на %T от %h (%s)</p> <!-- %c --> </div> </body></html> 
\ No newline at end of file
diff -u -r -N squid-3.2.0.14/errors/ca/ERR_CONFLICT_HOST squid-3.2.0.15/errors/ca/ERR_CONFLICT_HOST
--- squid-3.2.0.14/errors/ca/ERR_CONFLICT_HOST	1970-01-01 12:00:00.000000000 +1200
+++ squid-3.2.0.15/errors/ca/ERR_CONFLICT_HOST	2012-02-06 05:16:28.000000000 +1300
@@ -0,0 +1 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html><head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8"> <title>ERROR: No es pot mostrar la URL que heu sol.licitat</title> <style type="text/css"><!--   %l  body :lang(fa) { direction: rtl; font-size: 100%; font-family: Tahoma, Roya, sans-serif; float: right; } :lang(he) { direction: rtl; }  --></style> </head><body id=%c> <div id="titles"> <h1>ERROR</h1> <h2>No es pot mostrar la URL que heu sol.licitat</h2> </div> <hr>  <div id="content"> <p>The following error was encountered while trying to retrieve the URL: <a href="%U">%U</a></p>  <blockquote id="data"> <pre>URI Host Conflict</pre> </blockquote>  <p>This means the domain name you are trying to access apparently no longer exists on the machine you are requesting it from.</p>  <p>Some possible problems are:</p> <ul> <li>The domain may have moved very recently. Trying again will resolve that.</li> <li>The website may require you to use a local country-based version. Using your ISP provided DNS server(s) should resolve that.</li> </ul>  <p>L'administrador d'aquesta cache &eacute;s <a href="mailto:%w%W">%w</a>.</p> <br> </div>  <hr> <div id="footer"> <p>Generated %T by %h (%s)</p> <!-- %c --> </div> </body></html> 
\ No newline at end of file
diff -u -r -N squid-3.2.0.14/errors/cs/ERR_CONFLICT_HOST squid-3.2.0.15/errors/cs/ERR_CONFLICT_HOST
--- squid-3.2.0.14/errors/cs/ERR_CONFLICT_HOST	1970-01-01 12:00:00.000000000 +1200
+++ squid-3.2.0.15/errors/cs/ERR_CONFLICT_HOST	2012-02-06 05:18:00.000000000 +1300
@@ -0,0 +1 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html><head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8"> <title>CHYBA: Požadovaný dokument je nedostupný</title> <style type="text/css"><!--   %l  body :lang(fa) { direction: rtl; font-size: 100%; font-family: Tahoma, Roya, sans-serif; float: right; } :lang(he) { direction: rtl; }  --></style> </head><body id=%c> <div id="titles"> <h1>ERROR</h1> <h2>The requested URL could not be retrieved</h2> </div> <hr>  <div id="content"> <p>The following error was encountered while trying to retrieve the URL: <a href="%U">%U</a></p>  <blockquote id="data"> <pre>URI Host Conflict</pre> </blockquote>  <p>This means the domain name you are trying to access apparently no longer exists on the machine you are requesting it from.</p>  <p>Some possible problems are:</p> <ul> <li>The domain may have moved very recently. Trying again will resolve that.</li> <li>The website may require you to use a local country-based version. Using your ISP provided DNS server(s) should resolve that.</li> </ul>  <p>Your cache administrator is <a href="mailto:%w%W">%w</a>.</p> <br> </div>  <hr> <div id="footer"> <p>Generated %T by %h (%s)</p> <!-- %c --> </div> </body></html> 
\ No newline at end of file
diff -u -r -N squid-3.2.0.14/errors/da/ERR_CONFLICT_HOST squid-3.2.0.15/errors/da/ERR_CONFLICT_HOST
--- squid-3.2.0.14/errors/da/ERR_CONFLICT_HOST	1970-01-01 12:00:00.000000000 +1200
+++ squid-3.2.0.15/errors/da/ERR_CONFLICT_HOST	2012-02-06 05:19:03.000000000 +1300
@@ -0,0 +1 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html><head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8"> <title>FEJL: Den angivne URL kunne ikke hentes</title> <style type="text/css"><!--   %l  body :lang(fa) { direction: rtl; font-size: 100%; font-family: Tahoma, Roya, sans-serif; float: right; } :lang(he) { direction: rtl; }  --></style> </head><body id=%c> <div id="titles"> <h1>ERROR</h1> <h2>The requested URL could not be retrieved</h2> </div> <hr>  <div id="content"> <p>The following error was encountered while trying to retrieve the URL: <a href="%U">%U</a></p>  <blockquote id="data"> <pre>URI Host Conflict</pre> </blockquote>  <p>This means the domain name you are trying to access apparently no longer exists on the machine you are requesting it from.</p>  <p>Mulige problemer kan v&aelig;re:</p> <ul> <li>The domain may have moved very recently. Trying again will resolve that.</li> <li>The website may require you to use a local country-based version. Using your ISP provided DNS server(s) should resolve that.</li> </ul>  <p>Your cache administrator is <a href="mailto:%w%W">%w</a>.</p> <br> </div>  <hr> <div id="footer"> <p>Generated %T by %h (%s)</p> <!-- %c --> </div> </body></html> 
\ No newline at end of file
diff -u -r -N squid-3.2.0.14/errors/de/ERR_CONFLICT_HOST squid-3.2.0.15/errors/de/ERR_CONFLICT_HOST
--- squid-3.2.0.14/errors/de/ERR_CONFLICT_HOST	1970-01-01 12:00:00.000000000 +1200
+++ squid-3.2.0.15/errors/de/ERR_CONFLICT_HOST	2012-02-06 05:20:06.000000000 +1300
@@ -0,0 +1 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html><head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8"> <title>FEHLER: Die angeforderte URL konnte nicht gefunden werden</title> <style type="text/css"><!--   %l  body :lang(fa) { direction: rtl; font-size: 100%; font-family: Tahoma, Roya, sans-serif; float: right; } :lang(he) { direction: rtl; }  --></style> </head><body id=%c> <div id="titles"> <h1>ERROR</h1> <h2>The requested URL could not be retrieved</h2> </div> <hr>  <div id="content"> <p>Der folgende Fehler wurde beim Versuch die URL <a href="%U">%U</a> zu holen festgestellt:</p>  <blockquote id="data"> <pre>URI Host Conflict</pre> </blockquote>  <p>This means the domain name you are trying to access apparently no longer exists on the machine you are requesting it from.</p>  <p>Mögliche Probleme sind:</p> <ul> <li>The domain may have moved very recently. Trying again will resolve that.</li> <li>The website may require you to use a local country-based version. Using your ISP provided DNS server(s) should resolve that.</li> </ul>  <p>Ihr Cache Administrator ist <a href="mailto:%w%W">%w</a>.</p> <br> </div>  <hr> <div id="footer"> <p>Erzeugt am %T von %h (%s)</p> <!-- %c --> </div> </body></html> 
\ No newline at end of file
diff -u -r -N squid-3.2.0.14/errors/el/ERR_CONFLICT_HOST squid-3.2.0.15/errors/el/ERR_CONFLICT_HOST
--- squid-3.2.0.14/errors/el/ERR_CONFLICT_HOST	1970-01-01 12:00:00.000000000 +1200
+++ squid-3.2.0.15/errors/el/ERR_CONFLICT_HOST	2012-02-06 05:21:10.000000000 +1300
@@ -0,0 +1 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html><head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8"> <title>ΣΦΑΛΜΑ: The requested URL could not be retrieved</title> <style type="text/css"><!--   %l  body :lang(fa) { direction: rtl; font-size: 100%; font-family: Tahoma, Roya, sans-serif; float: right; } :lang(he) { direction: rtl; }  --></style> </head><body id=%c> <div id="titles"> <h1>ERROR</h1> <h2>The requested URL could not be retrieved</h2> </div> <hr>  <div id="content"> <p>The following error was encountered while trying to retrieve the URL: <a href="%U">%U</a></p>  <blockquote id="data"> <pre>URI Host Conflict</pre> </blockquote>  <p>This means the domain name you are trying to access apparently no longer exists on the machine you are requesting it from.</p>  <p>Some possible problems are:</p> <ul> <li>The domain may have moved very recently. Trying again will resolve that.</li> <li>The website may require you to use a local country-based version. Using your ISP provided DNS server(s) should resolve that.</li> </ul>  <p>Ο διαχειριστής του μεσολαβητή σας είναι ο <a href="mailto:%w%W">%w</a>.</p> <br> </div>  <hr> <div id="footer"> <p>Generated %T by %h (%s)</p> <!-- %c --> </div> </body></html> 
\ No newline at end of file
diff -u -r -N squid-3.2.0.14/errors/en/ERR_CONFLICT_HOST squid-3.2.0.15/errors/en/ERR_CONFLICT_HOST
--- squid-3.2.0.14/errors/en/ERR_CONFLICT_HOST	1970-01-01 12:00:00.000000000 +1200
+++ squid-3.2.0.15/errors/en/ERR_CONFLICT_HOST	2012-02-06 05:22:16.000000000 +1300
@@ -0,0 +1 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html><head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8"> <title>ERROR: The requested URL could not be retrieved</title> <style type="text/css"><!--   %l  body :lang(fa) { direction: rtl; font-size: 100%; font-family: Tahoma, Roya, sans-serif; float: right; } :lang(he) { direction: rtl; }  --></style> </head><body id=%c> <div id="titles"> <h1>ERROR</h1> <h2>The requested URL could not be retrieved</h2> </div> <hr>  <div id="content"> <p>The following error was encountered while trying to retrieve the URL: <a href="%U">%U</a></p>  <blockquote id="data"> <pre>URI Host Conflict</pre> </blockquote>  <p>This means the domain name you are trying to access apparently no longer exists on the machine you are requesting it from.</p>  <p>Some possible problems are:</p> <ul> <li>The domain may have moved very recently. Trying again will resolve that.</li> <li>The website may require you to use a local country-based version. Using your ISP provided DNS server(s) should resolve that.</li> </ul>  <p>Your cache administrator is <a href="mailto:%w%W">%w</a>.</p> <br> </div>  <hr> <div id="footer"> <p>Generated %T by %h (%s)</p> <!-- %c --> </div> </body></html> 
\ No newline at end of file
diff -u -r -N squid-3.2.0.14/errors/es/ERR_CONFLICT_HOST squid-3.2.0.15/errors/es/ERR_CONFLICT_HOST
--- squid-3.2.0.14/errors/es/ERR_CONFLICT_HOST	1970-01-01 12:00:00.000000000 +1200
+++ squid-3.2.0.15/errors/es/ERR_CONFLICT_HOST	2012-02-06 05:23:17.000000000 +1300
@@ -0,0 +1 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html><head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8"> <title>ERROR: El URL solicitado no se ha podido conseguir</title> <style type="text/css"><!--   %l  body :lang(fa) { direction: rtl; font-size: 100%; font-family: Tahoma, Roya, sans-serif; float: right; } :lang(he) { direction: rtl; }  --></style> </head><body id=%c> <div id="titles"> <h1>ERROR</h1> <h2>El URL solicitado no se ha podido conseguir</h2> </div> <hr>  <div id="content"> <p>Se encontró el siguiente error al intentar recuperar la dirección URL: <a href="%U">%U</a></p>  <blockquote id="data"> <pre>URI Host Conflict</pre> </blockquote>  <p>This means the domain name you are trying to access apparently no longer exists on the machine you are requesting it from.</p>  <p>Algunos posibles problemas son:</p> <ul> <li>The domain may have moved very recently. Trying again will resolve that.</li> <li>The website may require you to use a local country-based version. Using your ISP provided DNS server(s) should resolve that.</li> </ul>  <p>Su administrador del cach&eacute; es <a href="mailto:%w%W">%w</a>.</p> <br> </div>  <hr> <div id="footer"> <p>Generado %T por %h (%s)</p> <!-- %c --> </div> </body></html> 
\ No newline at end of file
diff -u -r -N squid-3.2.0.14/errors/et/ERR_CONFLICT_HOST squid-3.2.0.15/errors/et/ERR_CONFLICT_HOST
--- squid-3.2.0.14/errors/et/ERR_CONFLICT_HOST	1970-01-01 12:00:00.000000000 +1200
+++ squid-3.2.0.15/errors/et/ERR_CONFLICT_HOST	2012-02-06 05:24:19.000000000 +1300
@@ -0,0 +1 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html><head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8"> <title>VIGA: P&auml;ring URLile ei saa vastust</title> <style type="text/css"><!--   %l  body :lang(fa) { direction: rtl; font-size: 100%; font-family: Tahoma, Roya, sans-serif; float: right; } :lang(he) { direction: rtl; }  --></style> </head><body id=%c> <div id="titles"> <h1>ERROR</h1> <h2>The requested URL could not be retrieved</h2> </div> <hr>  <div id="content"> <p>The following error was encountered while trying to retrieve the URL: <a href="%U">%U</a></p>  <blockquote id="data"> <pre>URI Host Conflict</pre> </blockquote>  <p>This means the domain name you are trying to access apparently no longer exists on the machine you are requesting it from.</p>  <p>Some possible problems are:</p> <ul> <li>The domain may have moved very recently. Trying again will resolve that.</li> <li>The website may require you to use a local country-based version. Using your ISP provided DNS server(s) should resolve that.</li> </ul>  <p>Teie teenusepakkuja aadress on <a href="mailto:%w%W">%w</a>.</p> <br> </div>  <hr> <div id="footer"> <p>Generated %T by %h (%s)</p> <!-- %c --> </div> </body></html> 
\ No newline at end of file
diff -u -r -N squid-3.2.0.14/errors/fa/ERR_CONFLICT_HOST squid-3.2.0.15/errors/fa/ERR_CONFLICT_HOST
--- squid-3.2.0.14/errors/fa/ERR_CONFLICT_HOST	1970-01-01 12:00:00.000000000 +1200
+++ squid-3.2.0.15/errors/fa/ERR_CONFLICT_HOST	2012-02-06 05:25:22.000000000 +1300
@@ -0,0 +1 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html><head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8"> <title>خطا: The requested URL could not be retrieved</title> <style type="text/css"><!--   %l  body :lang(fa) { direction: rtl; font-size: 100%; font-family: Tahoma, Roya, sans-serif; float: right; } :lang(he) { direction: rtl; }  --></style> </head><body id=%c> <div id="titles"> <h1>ERROR</h1> <h2>The requested URL could not be retrieved</h2> </div> <hr>  <div id="content"> <p>The following error was encountered while trying to retrieve the URL: <a href="%U">%U</a></p>  <blockquote id="data"> <pre>URI Host Conflict</pre> </blockquote>  <p>This means the domain name you are trying to access apparently no longer exists on the machine you are requesting it from.</p>  <p>بعضی از مشکلات احتمالی:</p> <ul> <li>The domain may have moved very recently. Trying again will resolve that.</li> <li>The website may require you to use a local country-based version. Using your ISP provided DNS server(s) should resolve that.</li> </ul>  <p>Your cache administrator is <a href="mailto:%w%W">%w</a>.</p> <br> </div>  <hr> <div id="footer"> <p>%T توسط %h(%s) تولید شد.</p> <!-- %c --> </div> </body></html> 
\ No newline at end of file
diff -u -r -N squid-3.2.0.14/errors/fi/ERR_CONFLICT_HOST squid-3.2.0.15/errors/fi/ERR_CONFLICT_HOST
--- squid-3.2.0.14/errors/fi/ERR_CONFLICT_HOST	1970-01-01 12:00:00.000000000 +1200
+++ squid-3.2.0.15/errors/fi/ERR_CONFLICT_HOST	2012-02-06 05:26:30.000000000 +1300
@@ -0,0 +1 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html><head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8"> <title>VIRHE: Pyydettyä URL-osoitetta ei voitu hakea</title> <style type="text/css"><!--   %l  body :lang(fa) { direction: rtl; font-size: 100%; font-family: Tahoma, Roya, sans-serif; float: right; } :lang(he) { direction: rtl; }  --></style> </head><body id=%c> <div id="titles"> <h1>ERROR</h1> <h2>The requested URL could not be retrieved</h2> </div> <hr>  <div id="content"> <p>The following error was encountered while trying to retrieve the URL: <a href="%U">%U</a></p>  <blockquote id="data"> <pre>URI Host Conflict</pre> </blockquote>  <p>This means the domain name you are trying to access apparently no longer exists on the machine you are requesting it from.</p>  <p>Mahdollisia ongelmia:</p> <ul> <li>The domain may have moved very recently. Trying again will resolve that.</li> <li>The website may require you to use a local country-based version. Using your ISP provided DNS server(s) should resolve that.</li> </ul>  <p>Your cache administrator is <a href="mailto:%w%W">%w</a>.</p> <br> </div>  <hr> <div id="footer"> <p>Generated %T by %h (%s)</p> <!-- %c --> </div> </body></html> 
\ No newline at end of file
diff -u -r -N squid-3.2.0.14/errors/fr/ERR_CONFLICT_HOST squid-3.2.0.15/errors/fr/ERR_CONFLICT_HOST
--- squid-3.2.0.14/errors/fr/ERR_CONFLICT_HOST	1970-01-01 12:00:00.000000000 +1200
+++ squid-3.2.0.15/errors/fr/ERR_CONFLICT_HOST	2012-02-06 05:27:31.000000000 +1300
@@ -0,0 +1 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html><head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8"> <title>ERREUR: L'URL demandée n'a pas pu être trouvé</title> <style type="text/css"><!--   %l  body :lang(fa) { direction: rtl; font-size: 100%; font-family: Tahoma, Roya, sans-serif; float: right; } :lang(he) { direction: rtl; }  --></style> </head><body id=%c> <div id="titles"> <h1>ERROR</h1> <h2>The requested URL could not be retrieved</h2> </div> <hr>  <div id="content"> <p>L'erreur suivante s'est produite en essayant d'accéder à l'URL : <a href="%U">%U</a></p>  <blockquote id="data"> <pre>URI Host Conflict</pre> </blockquote>  <p>This means the domain name you are trying to access apparently no longer exists on the machine you are requesting it from.</p>  <p>Problèmes possibles :</p> <ul> <li>The domain may have moved very recently. Trying again will resolve that.</li> <li>The website may require you to use a local country-based version. Using your ISP provided DNS server(s) should resolve that.</li> </ul>  <p>Votre administrateur proxy est <a href="mailto:%w%W">%w</a>.</p> <br> </div>  <hr> <div id="footer"> <p>Générer le %T par %h (%s)</p> <!-- %c --> </div> </body></html> 
\ No newline at end of file
diff -u -r -N squid-3.2.0.14/errors/he/ERR_CONFLICT_HOST squid-3.2.0.15/errors/he/ERR_CONFLICT_HOST
--- squid-3.2.0.14/errors/he/ERR_CONFLICT_HOST	1970-01-01 12:00:00.000000000 +1200
+++ squid-3.2.0.15/errors/he/ERR_CONFLICT_HOST	2012-02-06 05:28:43.000000000 +1300
@@ -0,0 +1 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html><head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8"> <title>שגיאה: לא ניתן לגשת אל הכתובת המבוקשת</title> <style type="text/css"><!--   %l  body :lang(fa) { direction: rtl; font-size: 100%; font-family: Tahoma, Roya, sans-serif; float: right; } :lang(he) { direction: rtl; }  --></style> </head><body id=%c> <div id="titles"> <h1>ERROR</h1> <h2>The requested URL could not be retrieved</h2> </div> <hr>  <div id="content"> <p>השגיאה הבאה אירעה בעת ניסיון לפענח את כתובת הURL: <a href="%U">%U</a></p>  <blockquote id="data"> <pre>URI Host Conflict</pre> </blockquote>  <p>This means the domain name you are trying to access apparently no longer exists on the machine you are requesting it from.</p>  <p>Some possible problems are:</p> <ul> <li>The domain may have moved very recently. Trying again will resolve that.</li> <li>The website may require you to use a local country-based version. Using your ISP provided DNS server(s) should resolve that.</li> </ul>  <p>מנהל השרת הוא <a href="mailto:%w%W">%w</a>. </p> <br> </div>  <hr> <div id="footer"> <p>נוצר %T על ידי %h (%s)</p> <!-- %c --> </div> </body></html> 
\ No newline at end of file
diff -u -r -N squid-3.2.0.14/errors/hu/ERR_CONFLICT_HOST squid-3.2.0.15/errors/hu/ERR_CONFLICT_HOST
--- squid-3.2.0.14/errors/hu/ERR_CONFLICT_HOST	1970-01-01 12:00:00.000000000 +1200
+++ squid-3.2.0.15/errors/hu/ERR_CONFLICT_HOST	2012-02-06 05:30:07.000000000 +1300
@@ -0,0 +1 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html><head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8"> <title>HIBA: A kért URL nem tölthető le</title> <style type="text/css"><!--   %l  body :lang(fa) { direction: rtl; font-size: 100%; font-family: Tahoma, Roya, sans-serif; float: right; } :lang(he) { direction: rtl; }  --></style> </head><body id=%c> <div id="titles"> <h1>ERROR</h1> <h2>The requested URL could not be retrieved</h2> </div> <hr>  <div id="content"> <p>The following error was encountered while trying to retrieve the URL: <a href="%U">%U</a></p>  <blockquote id="data"> <pre>URI Host Conflict</pre> </blockquote>  <p>This means the domain name you are trying to access apparently no longer exists on the machine you are requesting it from.</p>  <p>Néhány lehetséges probléma:</p> <ul> <li>The domain may have moved very recently. Trying again will resolve that.</li> <li>The website may require you to use a local country-based version. Using your ISP provided DNS server(s) should resolve that.</li> </ul>  <p>Your cache administrator is <a href="mailto:%w%W">%w</a>.</p> <br> </div>  <hr> <div id="footer"> <p>Generated %T by %h (%s)</p> <!-- %c --> </div> </body></html> 
\ No newline at end of file
diff -u -r -N squid-3.2.0.14/errors/hy/ERR_CONFLICT_HOST squid-3.2.0.15/errors/hy/ERR_CONFLICT_HOST
--- squid-3.2.0.14/errors/hy/ERR_CONFLICT_HOST	1970-01-01 12:00:00.000000000 +1200
+++ squid-3.2.0.15/errors/hy/ERR_CONFLICT_HOST	2012-02-06 05:31:41.000000000 +1300
@@ -0,0 +1 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html><head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8"> <title>ՍԽԱԼ: Պահանջվող URL-ն հնարավոր չէ ստանալ</title> <style type="text/css"><!--   %l  body :lang(fa) { direction: rtl; font-size: 100%; font-family: Tahoma, Roya, sans-serif; float: right; } :lang(he) { direction: rtl; }  --></style> </head><body id=%c> <div id="titles"> <h1>ERROR</h1> <h2>The requested URL could not be retrieved</h2> </div> <hr>  <div id="content"> <p>URL-ի ստացման ընթացքում առաջացավ հետևյալ սխալը: <a href="%U">%U</a></p>  <blockquote id="data"> <pre>URI Host Conflict</pre> </blockquote>  <p>This means the domain name you are trying to access apparently no longer exists on the machine you are requesting it from.</p>  <p>Հնարավոր պատճառներն են:</p> <ul> <li>The domain may have moved very recently. Trying again will resolve that.</li> <li>The website may require you to use a local country-based version. Using your ISP provided DNS server(s) should resolve that.</li> </ul>  <p>Ձեր քեշի կառավարիչը <a href="mailto:%w%W">%w</a> է.</p> <br> </div>  <hr> <div id="footer"> <p>Ստեղծված է %T by %h (%s)</p> <!-- %c --> </div> </body></html> 
\ No newline at end of file
diff -u -r -N squid-3.2.0.14/errors/id/ERR_CONFLICT_HOST squid-3.2.0.15/errors/id/ERR_CONFLICT_HOST
--- squid-3.2.0.14/errors/id/ERR_CONFLICT_HOST	1970-01-01 12:00:00.000000000 +1200
+++ squid-3.2.0.15/errors/id/ERR_CONFLICT_HOST	2012-02-06 05:33:05.000000000 +1300
@@ -0,0 +1 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html><head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8"> <title>ERROR: The requested URL could not be retrieved</title> <style type="text/css"><!--   %l  body :lang(fa) { direction: rtl; font-size: 100%; font-family: Tahoma, Roya, sans-serif; float: right; } :lang(he) { direction: rtl; }  --></style> </head><body id=%c> <div id="titles"> <h1>ERROR</h1> <h2>The requested URL could not be retrieved</h2> </div> <hr>  <div id="content"> <p>The following error was encountered while trying to retrieve the URL: <a href="%U">%U</a></p>  <blockquote id="data"> <pre>URI Host Conflict</pre> </blockquote>  <p>This means the domain name you are trying to access apparently no longer exists on the machine you are requesting it from.</p>  <p>Some possible problems are:</p> <ul> <li>The domain may have moved very recently. Trying again will resolve that.</li> <li>The website may require you to use a local country-based version. Using your ISP provided DNS server(s) should resolve that.</li> </ul>  <p>Your cache administrator is <a href="mailto:%w%W">%w</a>.</p> <br> </div>  <hr> <div id="footer"> <p>Generated %T by %h (%s)</p> <!-- %c --> </div> </body></html> 
\ No newline at end of file
diff -u -r -N squid-3.2.0.14/errors/it/ERR_CONFLICT_HOST squid-3.2.0.15/errors/it/ERR_CONFLICT_HOST
--- squid-3.2.0.14/errors/it/ERR_CONFLICT_HOST	1970-01-01 12:00:00.000000000 +1200
+++ squid-3.2.0.15/errors/it/ERR_CONFLICT_HOST	2012-02-06 05:34:10.000000000 +1300
@@ -0,0 +1 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html><head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8"> <title>ERRORE: Non è stato possibile accedere alla URL richiesta.</title> <style type="text/css"><!--   %l  body :lang(fa) { direction: rtl; font-size: 100%; font-family: Tahoma, Roya, sans-serif; float: right; } :lang(he) { direction: rtl; }  --></style> </head><body id=%c> <div id="titles"> <h1>ERROR</h1> <h2>The requested URL could not be retrieved</h2> </div> <hr>  <div id="content"> <p>Mentre si cercava di accedere alla URL <a href="%U">%U</a> si è presentato il seguente errore:</p>  <blockquote id="data"> <pre>URI Host Conflict</pre> </blockquote>  <p>This means the domain name you are trying to access apparently no longer exists on the machine you are requesting it from.</p>  <p>Alcuni dei possibili problemi sono:</p> <ul> <li>The domain may have moved very recently. Trying again will resolve that.</li> <li>The website may require you to use a local country-based version. Using your ISP provided DNS server(s) should resolve that.</li> </ul>  <p>L'amministratore del proxy è <a href="mailto:%w%W">%w</a>.</p> <br> </div>  <hr> <div id="footer"> <p>Generato da %h (%s) il %T.</p> <!-- %c --> </div> </body></html> 
\ No newline at end of file
diff -u -r -N squid-3.2.0.14/errors/ja/ERR_CONFLICT_HOST squid-3.2.0.15/errors/ja/ERR_CONFLICT_HOST
--- squid-3.2.0.14/errors/ja/ERR_CONFLICT_HOST	1970-01-01 12:00:00.000000000 +1200
+++ squid-3.2.0.15/errors/ja/ERR_CONFLICT_HOST	2012-02-06 05:35:15.000000000 +1300
@@ -0,0 +1 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html><head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8"> <title>エラー: リクエストされた URL は取得できませんでした</title> <style type="text/css"><!--   %l  body :lang(fa) { direction: rtl; font-size: 100%; font-family: Tahoma, Roya, sans-serif; float: right; } :lang(he) { direction: rtl; }  --></style> </head><body id=%c> <div id="titles"> <h1>ERROR</h1> <h2>The requested URL could not be retrieved</h2> </div> <hr>  <div id="content"> <p>The following error was encountered while trying to retrieve the URL: <a href="%U">%U</a></p>  <blockquote id="data"> <pre>URI Host Conflict</pre> </blockquote>  <p>This means the domain name you are trying to access apparently no longer exists on the machine you are requesting it from.</p>  <p>ありそうな問題: </p> <ul> <li>The domain may have moved very recently. Trying again will resolve that.</li> <li>The website may require you to use a local country-based version. Using your ISP provided DNS server(s) should resolve that.</li> </ul>  <p>Your cache administrator is <a href="mailto:%w%W">%w</a>.</p> <br> </div>  <hr> <div id="footer"> <p>%Tに%h (%s)が生成しました。</p> <!-- %c --> </div> </body></html> 
\ No newline at end of file
diff -u -r -N squid-3.2.0.14/errors/ko/ERR_CONFLICT_HOST squid-3.2.0.15/errors/ko/ERR_CONFLICT_HOST
--- squid-3.2.0.14/errors/ko/ERR_CONFLICT_HOST	1970-01-01 12:00:00.000000000 +1200
+++ squid-3.2.0.15/errors/ko/ERR_CONFLICT_HOST	2012-02-06 05:36:32.000000000 +1300
@@ -0,0 +1 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html><head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8"> <title>에러: 요청된 URL을 가져올 수 없습니다.</title> <style type="text/css"><!--   %l  body :lang(fa) { direction: rtl; font-size: 100%; font-family: Tahoma, Roya, sans-serif; float: right; } :lang(he) { direction: rtl; }  --></style> </head><body id=%c> <div id="titles"> <h1>ERROR</h1> <h2>The requested URL could not be retrieved</h2> </div> <hr>  <div id="content"> <p>The following error was encountered while trying to retrieve the URL: <a href="%U">%U</a></p>  <blockquote id="data"> <pre>URI Host Conflict</pre> </blockquote>  <p>This means the domain name you are trying to access apparently no longer exists on the machine you are requesting it from.</p>  <p>Some possible problems are:</p> <ul> <li>The domain may have moved very recently. Trying again will resolve that.</li> <li>The website may require you to use a local country-based version. Using your ISP provided DNS server(s) should resolve that.</li> </ul>  <p>Your cache administrator is <a href="mailto:%w%W">%w</a>.</p> <br> </div>  <hr> <div id="footer"> <p>Generated %T by %h (%s)</p> <!-- %c --> </div> </body></html> 
\ No newline at end of file
diff -u -r -N squid-3.2.0.14/errors/lt/ERR_CONFLICT_HOST squid-3.2.0.15/errors/lt/ERR_CONFLICT_HOST
--- squid-3.2.0.14/errors/lt/ERR_CONFLICT_HOST	1970-01-01 12:00:00.000000000 +1200
+++ squid-3.2.0.15/errors/lt/ERR_CONFLICT_HOST	2012-02-06 05:38:14.000000000 +1300
@@ -0,0 +1 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html><head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8"> <title>KLAIDA: Puslapis nurodytu adresu negali būti atsiųstas</title> <style type="text/css"><!--   %l  body :lang(fa) { direction: rtl; font-size: 100%; font-family: Tahoma, Roya, sans-serif; float: right; } :lang(he) { direction: rtl; }  --></style> </head><body id=%c> <div id="titles"> <h1>ERROR</h1> <h2>The requested URL could not be retrieved</h2> </div> <hr>  <div id="content"> <p>The following error was encountered while trying to retrieve the URL: <a href="%U">%U</a></p>  <blockquote id="data"> <pre>URI Host Conflict</pre> </blockquote>  <p>This means the domain name you are trying to access apparently no longer exists on the machine you are requesting it from.</p>  <p>Some possible problems are:</p> <ul> <li>The domain may have moved very recently. Trying again will resolve that.</li> <li>The website may require you to use a local country-based version. Using your ISP provided DNS server(s) should resolve that.</li> </ul>  <p>Your cache administrator is <a href="mailto:%w%W">%w</a>.</p> <br> </div>  <hr> <div id="footer"> <p>Generated %T by %h (%s)</p> <!-- %c --> </div> </body></html> 
\ No newline at end of file
diff -u -r -N squid-3.2.0.14/errors/lv/ERR_CONFLICT_HOST squid-3.2.0.15/errors/lv/ERR_CONFLICT_HOST
--- squid-3.2.0.14/errors/lv/ERR_CONFLICT_HOST	1970-01-01 12:00:00.000000000 +1200
+++ squid-3.2.0.15/errors/lv/ERR_CONFLICT_HOST	2012-02-06 05:39:30.000000000 +1300
@@ -0,0 +1 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html><head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8"> <title>Kļūda: Nevar atvērt pieprasīto adresi.</title> <style type="text/css"><!--   %l  body :lang(fa) { direction: rtl; font-size: 100%; font-family: Tahoma, Roya, sans-serif; float: right; } :lang(he) { direction: rtl; }  --></style> </head><body id=%c> <div id="titles"> <h1>ERROR</h1> <h2>The requested URL could not be retrieved</h2> </div> <hr>  <div id="content"> <p>Iestājusies sekojoša kļūda mēģinot atvērt adresi: <a href="%U">%U</a></p>  <blockquote id="data"> <pre>URI Host Conflict</pre> </blockquote>  <p>This means the domain name you are trying to access apparently no longer exists on the machine you are requesting it from.</p>  <p>Dažas iespējamās problēmas ir:</p> <ul> <li>The domain may have moved very recently. Trying again will resolve that.</li> <li>The website may require you to use a local country-based version. Using your ISP provided DNS server(s) should resolve that.</li> </ul>  <p>Jūsu kešatmiņas administrators ir <a href="mailto:%w%W">%w</a>.</p> <br> </div>  <hr> <div id="footer"> <p>Ģenerēts %T by %h (%s)</p> <!-- %c --> </div> </body></html> 
\ No newline at end of file
diff -u -r -N squid-3.2.0.14/errors/Makefile.in squid-3.2.0.15/errors/Makefile.in
--- squid-3.2.0.14/errors/Makefile.in	2011-12-13 00:10:11.000000000 +1300
+++ squid-3.2.0.15/errors/Makefile.in	2012-02-06 04:57:26.000000000 +1300
@@ -277,6 +277,7 @@
     templates/ERR_CACHE_ACCESS_DENIED \
     templates/ERR_CACHE_MGR_ACCESS_DENIED \
     templates/ERR_CANNOT_FORWARD \
+    templates/ERR_CONFLICT_HOST \
     templates/ERR_CONNECT_FAIL \
     templates/ERR_DIR_LISTING \
     templates/ERR_DNS_FAIL \
diff -u -r -N squid-3.2.0.14/errors/ms/ERR_CONFLICT_HOST squid-3.2.0.15/errors/ms/ERR_CONFLICT_HOST
--- squid-3.2.0.14/errors/ms/ERR_CONFLICT_HOST	1970-01-01 12:00:00.000000000 +1200
+++ squid-3.2.0.15/errors/ms/ERR_CONFLICT_HOST	2012-02-06 05:40:33.000000000 +1300
@@ -0,0 +1 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html><head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8"> <title>RALAT: The requested URL could not be retrieved</title> <style type="text/css"><!--   %l  body :lang(fa) { direction: rtl; font-size: 100%; font-family: Tahoma, Roya, sans-serif; float: right; } :lang(he) { direction: rtl; }  --></style> </head><body id=%c> <div id="titles"> <h1>ERROR</h1> <h2>The requested URL could not be retrieved</h2> </div> <hr>  <div id="content"> <p>The following error was encountered while trying to retrieve the URL: <a href="%U">%U</a></p>  <blockquote id="data"> <pre>URI Host Conflict</pre> </blockquote>  <p>This means the domain name you are trying to access apparently no longer exists on the machine you are requesting it from.</p>  <p>Some possible problems are:</p> <ul> <li>The domain may have moved very recently. Trying again will resolve that.</li> <li>The website may require you to use a local country-based version. Using your ISP provided DNS server(s) should resolve that.</li> </ul>  <p>Pengurus Proxy anda ialah <a href="mailto:%w%W">%w</a>.</p> <br> </div>  <hr> <div id="footer"> <p>Dibuat pada %T by %h (%s)</p> <!-- %c --> </div> </body></html> 
\ No newline at end of file
diff -u -r -N squid-3.2.0.14/errors/nl/ERR_CONFLICT_HOST squid-3.2.0.15/errors/nl/ERR_CONFLICT_HOST
--- squid-3.2.0.14/errors/nl/ERR_CONFLICT_HOST	1970-01-01 12:00:00.000000000 +1200
+++ squid-3.2.0.15/errors/nl/ERR_CONFLICT_HOST	2012-02-06 05:41:35.000000000 +1300
@@ -0,0 +1 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html><head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8"> <title>FOUT: De gevraagde URL kon niet worden opgehaald</title> <style type="text/css"><!--   %l  body :lang(fa) { direction: rtl; font-size: 100%; font-family: Tahoma, Roya, sans-serif; float: right; } :lang(he) { direction: rtl; }  --></style> </head><body id=%c> <div id="titles"> <h1>ERROR</h1> <h2>The requested URL could not be retrieved</h2> </div> <hr>  <div id="content"> <p>De volgende fout is opgetreden tijdens het ophalen van URL: <a href="%U">%U</a></p>  <blockquote id="data"> <pre>URI Host Conflict</pre> </blockquote>  <p>This means the domain name you are trying to access apparently no longer exists on the machine you are requesting it from.</p>  <p>Mogelijke problemen zijn:</p> <ul> <li>The domain may have moved very recently. Trying again will resolve that.</li> <li>The website may require you to use a local country-based version. Using your ISP provided DNS server(s) should resolve that.</li> </ul>  <p>De beheerder van deze cache is <a href="mailto:%w%W">%w</a>.</p> <br> </div>  <hr> <div id="footer"> <p>Gegenereerd %T door %h (%s)</p> <!-- %c --> </div> </body></html> 
\ No newline at end of file
diff -u -r -N squid-3.2.0.14/errors/oc/ERR_CONFLICT_HOST squid-3.2.0.15/errors/oc/ERR_CONFLICT_HOST
--- squid-3.2.0.14/errors/oc/ERR_CONFLICT_HOST	1970-01-01 12:00:00.000000000 +1200
+++ squid-3.2.0.15/errors/oc/ERR_CONFLICT_HOST	2012-02-06 05:42:34.000000000 +1300
@@ -0,0 +1 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html><head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8"> <title>ERREUR : L'URL demandada a pas pogut èsser cargada</title> <style type="text/css"><!--   %l  body :lang(fa) { direction: rtl; font-size: 100%; font-family: Tahoma, Roya, sans-serif; float: right; } :lang(he) { direction: rtl; }  --></style> </head><body id=%c> <div id="titles"> <h1>ERROR</h1> <h2>L'URL demandada a pas pogut èsser cargada</h2> </div> <hr>  <div id="content"> <p>L'error seguenta s'es producha en ensajant d'accedir a l'URL : <a href="%U">%U</a></p>  <blockquote id="data"> <pre>URI Host Conflict</pre> </blockquote>  <p>This means the domain name you are trying to access apparently no longer exists on the machine you are requesting it from.</p>  <p>Problèmas envisajables :</p> <ul> <li>The domain may have moved very recently. Trying again will resolve that.</li> <li>The website may require you to use a local country-based version. Using your ISP provided DNS server(s) should resolve that.</li> </ul>  <p>Vòstre administrator d'amagatal es <a href="mailto:%w">%w</a>.</p> <br> </div>  <hr> <div id="footer"> <p>Generada lo %T per %h (%s)</p> <!-- %c --> </div> </body></html> 
\ No newline at end of file
diff -u -r -N squid-3.2.0.14/errors/pl/ERR_CONFLICT_HOST squid-3.2.0.15/errors/pl/ERR_CONFLICT_HOST
--- squid-3.2.0.14/errors/pl/ERR_CONFLICT_HOST	1970-01-01 12:00:00.000000000 +1200
+++ squid-3.2.0.15/errors/pl/ERR_CONFLICT_HOST	2012-02-06 05:43:33.000000000 +1300
@@ -0,0 +1 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html><head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8"> <title>BŁĄD: Żądany URL nie może zostać pobrany</title> <style type="text/css"><!--   %l  body :lang(fa) { direction: rtl; font-size: 100%; font-family: Tahoma, Roya, sans-serif; float: right; } :lang(he) { direction: rtl; }  --></style> </head><body id=%c> <div id="titles"> <h1>ERROR</h1> <h2>The requested URL could not be retrieved</h2> </div> <hr>  <div id="content"> <p>The following error was encountered while trying to retrieve the URL: <a href="%U">%U</a></p>  <blockquote id="data"> <pre>URI Host Conflict</pre> </blockquote>  <p>This means the domain name you are trying to access apparently no longer exists on the machine you are requesting it from.</p>  <p>Some possible problems are:</p> <ul> <li>The domain may have moved very recently. Trying again will resolve that.</li> <li>The website may require you to use a local country-based version. Using your ISP provided DNS server(s) should resolve that.</li> </ul>  <p>Your cache administrator is <a href="mailto:%w%W">%w</a>.</p> <br> </div>  <hr> <div id="footer"> <p>Utworzono %T przez %h (%s)</p> <!-- %c --> </div> </body></html> 
\ No newline at end of file
diff -u -r -N squid-3.2.0.14/errors/pt/ERR_CONFLICT_HOST squid-3.2.0.15/errors/pt/ERR_CONFLICT_HOST
--- squid-3.2.0.14/errors/pt/ERR_CONFLICT_HOST	1970-01-01 12:00:00.000000000 +1200
+++ squid-3.2.0.15/errors/pt/ERR_CONFLICT_HOST	2012-02-06 05:45:36.000000000 +1300
@@ -0,0 +1 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html><head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8"> <title>ERRO: A URL solicitada não pode ser recuperada</title> <style type="text/css"><!--   %l  body :lang(fa) { direction: rtl; font-size: 100%; font-family: Tahoma, Roya, sans-serif; float: right; } :lang(he) { direction: rtl; }  --></style> </head><body id=%c> <div id="titles"> <h1>ERROR</h1> <h2>The requested URL could not be retrieved</h2> </div> <hr>  <div id="content"> <p>The following error was encountered while trying to retrieve the URL: <a href="%U">%U</a></p>  <blockquote id="data"> <pre>URI Host Conflict</pre> </blockquote>  <p>This means the domain name you are trying to access apparently no longer exists on the machine you are requesting it from.</p>  <p>Some possible problems are:</p> <ul> <li>The domain may have moved very recently. Trying again will resolve that.</li> <li>The website may require you to use a local country-based version. Using your ISP provided DNS server(s) should resolve that.</li> </ul>  <p>Your cache administrator is <a href="mailto:%w%W">%w</a>.</p> <br> </div>  <hr> <div id="footer"> <p>Generated %T by %h (%s)</p> <!-- %c --> </div> </body></html> 
\ No newline at end of file
diff -u -r -N squid-3.2.0.14/errors/pt-br/ERR_CONFLICT_HOST squid-3.2.0.15/errors/pt-br/ERR_CONFLICT_HOST
--- squid-3.2.0.14/errors/pt-br/ERR_CONFLICT_HOST	1970-01-01 12:00:00.000000000 +1200
+++ squid-3.2.0.15/errors/pt-br/ERR_CONFLICT_HOST	2012-02-06 05:44:35.000000000 +1300
@@ -0,0 +1 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html><head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8"> <title>ERRO: A URL requisitada não pôde ser recuperada</title> <style type="text/css"><!--   %l  body :lang(fa) { direction: rtl; font-size: 100%; font-family: Tahoma, Roya, sans-serif; float: right; } :lang(he) { direction: rtl; }  --></style> </head><body id=%c> <div id="titles"> <h1>ERROR</h1> <h2>The requested URL could not be retrieved</h2> </div> <hr>  <div id="content"> <p>O seguinte erro foi encontrado ao tentar recuperar a URL: <a href="%U">%U</a></p>  <blockquote id="data"> <pre>URI Host Conflict</pre> </blockquote>  <p>This means the domain name you are trying to access apparently no longer exists on the machine you are requesting it from.</p>  <p>Alguns dos possíveis problemas são:</p> <ul> <li>The domain may have moved very recently. Trying again will resolve that.</li> <li>The website may require you to use a local country-based version. Using your ISP provided DNS server(s) should resolve that.</li> </ul>  <p>Seu administrador do cache é <a href="mailto:%w%W">%w</a>.</p> <br> </div>  <hr> <div id="footer"> <p>Gerado %T por %h (%s)</p> <!-- %c --> </div> </body></html> 
\ No newline at end of file
diff -u -r -N squid-3.2.0.14/errors/ro/ERR_CONFLICT_HOST squid-3.2.0.15/errors/ro/ERR_CONFLICT_HOST
--- squid-3.2.0.14/errors/ro/ERR_CONFLICT_HOST	1970-01-01 12:00:00.000000000 +1200
+++ squid-3.2.0.15/errors/ro/ERR_CONFLICT_HOST	2012-02-06 05:46:45.000000000 +1300
@@ -0,0 +1 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html><head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8"> <title>EROARE: URL-ul cerut nu a putut fi accesat</title> <style type="text/css"><!--   %l  body :lang(fa) { direction: rtl; font-size: 100%; font-family: Tahoma, Roya, sans-serif; float: right; } :lang(he) { direction: rtl; }  --></style> </head><body id=%c> <div id="titles"> <h1>ERROR</h1> <h2>The requested URL could not be retrieved</h2> </div> <hr>  <div id="content"> <p>S-a recepţionat următoarea eroare când se încerca accesarea URL-ului: <a href="%U">%U</a></p>  <blockquote id="data"> <pre>URI Host Conflict</pre> </blockquote>  <p>This means the domain name you are trying to access apparently no longer exists on the machine you are requesting it from.</p>  <p>Unele posibile probleme sunt:</p> <ul> <li>The domain may have moved very recently. Trying again will resolve that.</li> <li>The website may require you to use a local country-based version. Using your ISP provided DNS server(s) should resolve that.</li> </ul>  <p>Administratorul cache-ului este <a href="mailto:%w%W">%w</a>.</p> <br> </div>  <hr> <div id="footer"> <p>Generat %T de către %h (%s)</p> <!-- %c --> </div> </body></html> 
\ No newline at end of file
diff -u -r -N squid-3.2.0.14/errors/ru/ERR_CONFLICT_HOST squid-3.2.0.15/errors/ru/ERR_CONFLICT_HOST
--- squid-3.2.0.14/errors/ru/ERR_CONFLICT_HOST	1970-01-01 12:00:00.000000000 +1200
+++ squid-3.2.0.15/errors/ru/ERR_CONFLICT_HOST	2012-02-06 05:47:43.000000000 +1300
@@ -0,0 +1 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html><head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8"> <title>ОШИБКА: Запрошенный URL не может быть получен</title> <style type="text/css"><!--   %l  body :lang(fa) { direction: rtl; font-size: 100%; font-family: Tahoma, Roya, sans-serif; float: right; } :lang(he) { direction: rtl; }  --></style> </head><body id=%c> <div id="titles"> <h1>ERROR</h1> <h2>The requested URL could not be retrieved</h2> </div> <hr>  <div id="content"> <p>При получении URL <a href="%U">%U</a> произошла следующая ошибка</p>  <blockquote id="data"> <pre>URI Host Conflict</pre> </blockquote>  <p>This means the domain name you are trying to access apparently no longer exists on the machine you are requesting it from.</p>  <p>Возможные проблемы:</p> <ul> <li>The domain may have moved very recently. Trying again will resolve that.</li> <li>The website may require you to use a local country-based version. Using your ISP provided DNS server(s) should resolve that.</li> </ul>  <p>Администратор Вашего кэша: <a href="mailto:%w%W">%w</a>.</p> <br> </div>  <hr> <div id="footer"> <p>Создано %T на %h (%s)</p> <!-- %c --> </div> </body></html> 
\ No newline at end of file
diff -u -r -N squid-3.2.0.14/errors/sk/ERR_CONFLICT_HOST squid-3.2.0.15/errors/sk/ERR_CONFLICT_HOST
--- squid-3.2.0.14/errors/sk/ERR_CONFLICT_HOST	1970-01-01 12:00:00.000000000 +1200
+++ squid-3.2.0.15/errors/sk/ERR_CONFLICT_HOST	2012-02-06 05:48:41.000000000 +1300
@@ -0,0 +1 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html><head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8"> <title>CHYBA: Požadovaný URL nebolo možné získať</title> <style type="text/css"><!--   %l  body :lang(fa) { direction: rtl; font-size: 100%; font-family: Tahoma, Roya, sans-serif; float: right; } :lang(he) { direction: rtl; }  --></style> </head><body id=%c> <div id="titles"> <h1>ERROR</h1> <h2>The requested URL could not be retrieved</h2> </div> <hr>  <div id="content"> <p>Pri pokuse o získanie URL sa vyskytla nasledovná chyba: <a href="%U">%U</a></p>  <blockquote id="data"> <pre>URI Host Conflict</pre> </blockquote>  <p>This means the domain name you are trying to access apparently no longer exists on the machine you are requesting it from.</p>  <p>Niektoré možné problémy:</p> <ul> <li>The domain may have moved very recently. Trying again will resolve that.</li> <li>The website may require you to use a local country-based version. Using your ISP provided DNS server(s) should resolve that.</li> </ul>  <p>Vaším správcom cache je <a href="mailto:%w%W">%w</a>.</p> <br> </div>  <hr> <div id="footer"> <p>Vytvoril %T, %h (%s)</p> <!-- %c --> </div> </body></html> 
\ No newline at end of file
diff -u -r -N squid-3.2.0.14/errors/sl/ERR_CONFLICT_HOST squid-3.2.0.15/errors/sl/ERR_CONFLICT_HOST
--- squid-3.2.0.14/errors/sl/ERR_CONFLICT_HOST	1970-01-01 12:00:00.000000000 +1200
+++ squid-3.2.0.15/errors/sl/ERR_CONFLICT_HOST	2012-02-06 05:49:40.000000000 +1300
@@ -0,0 +1 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html><head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8"> <title>NAPAKA: Zahtevanega naslova URL ni bilo mogoče naložiti</title> <style type="text/css"><!--   %l  body :lang(fa) { direction: rtl; font-size: 100%; font-family: Tahoma, Roya, sans-serif; float: right; } :lang(he) { direction: rtl; }  --></style> </head><body id=%c> <div id="titles"> <h1>ERROR</h1> <h2>The requested URL could not be retrieved</h2> </div> <hr>  <div id="content"> <p>Prišlo je do napake med poskusom nalaganja naslova URL: <a href="%U">%U</a></p>  <blockquote id="data"> <pre>URI Host Conflict</pre> </blockquote>  <p>This means the domain name you are trying to access apparently no longer exists on the machine you are requesting it from.</p>  <p>Težave so lahko med drugim:</p> <ul> <li>The domain may have moved very recently. Trying again will resolve that.</li> <li>The website may require you to use a local country-based version. Using your ISP provided DNS server(s) should resolve that.</li> </ul>  <p>Skrbnik vašega predpomnilnika je <a href="mailto:%w%W">%w</a>.</p> <br> </div>  <hr> <div id="footer"> <p>Ustvaril %h (%s) dne %T</p> <!-- %c --> </div> </body></html> 
\ No newline at end of file
diff -u -r -N squid-3.2.0.14/errors/sr-cyrl/ERR_CONFLICT_HOST squid-3.2.0.15/errors/sr-cyrl/ERR_CONFLICT_HOST
--- squid-3.2.0.14/errors/sr-cyrl/ERR_CONFLICT_HOST	1970-01-01 12:00:00.000000000 +1200
+++ squid-3.2.0.15/errors/sr-cyrl/ERR_CONFLICT_HOST	2012-02-06 05:50:56.000000000 +1300
@@ -0,0 +1 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html><head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8"> <title>ERROR: The requested URL could not be retrieved</title> <style type="text/css"><!--   %l  body :lang(fa) { direction: rtl; font-size: 100%; font-family: Tahoma, Roya, sans-serif; float: right; } :lang(he) { direction: rtl; }  --></style> </head><body id=%c> <div id="titles"> <h1>ERROR</h1> <h2>The requested URL could not be retrieved</h2> </div> <hr>  <div id="content"> <p>The following error was encountered while trying to retrieve the URL: <a href="%U">%U</a></p>  <blockquote id="data"> <pre>URI Host Conflict</pre> </blockquote>  <p>This means the domain name you are trying to access apparently no longer exists on the machine you are requesting it from.</p>  <p>Some possible problems are:</p> <ul> <li>The domain may have moved very recently. Trying again will resolve that.</li> <li>The website may require you to use a local country-based version. Using your ISP provided DNS server(s) should resolve that.</li> </ul>  <p>Your cache administrator is <a href="mailto:%w%W">%w</a>.</p> <br> </div>  <hr> <div id="footer"> <p>Generated %T by %h (%s)</p> <!-- %c --> </div> </body></html> 
\ No newline at end of file
diff -u -r -N squid-3.2.0.14/errors/sr-latn/ERR_CONFLICT_HOST squid-3.2.0.15/errors/sr-latn/ERR_CONFLICT_HOST
--- squid-3.2.0.14/errors/sr-latn/ERR_CONFLICT_HOST	1970-01-01 12:00:00.000000000 +1200
+++ squid-3.2.0.15/errors/sr-latn/ERR_CONFLICT_HOST	2012-02-06 05:52:17.000000000 +1300
@@ -0,0 +1 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html><head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8"> <title>GREŠKA: Tražena adresa (URL) ne može da se učita</title> <style type="text/css"><!--   %l  body :lang(fa) { direction: rtl; font-size: 100%; font-family: Tahoma, Roya, sans-serif; float: right; } :lang(he) { direction: rtl; }  --></style> </head><body id=%c> <div id="titles"> <h1>ERROR</h1> <h2>The requested URL could not be retrieved</h2> </div> <hr>  <div id="content"> <p>Greška učitavanja podataka sa adrese (URL): <a href="%U">%U</a></p>  <blockquote id="data"> <pre>URI Host Conflict</pre> </blockquote>  <p>This means the domain name you are trying to access apparently no longer exists on the machine you are requesting it from.</p>  <p>Mogući problemi su:</p> <ul> <li>The domain may have moved very recently. Trying again will resolve that.</li> <li>The website may require you to use a local country-based version. Using your ISP provided DNS server(s) should resolve that.</li> </ul>  <p>Vaš keš/proksi administrator je: <a href="mailto:%w%W">%w</a>.</p> <br> </div>  <hr> <div id="footer"> <p>Generisano %T sa %h (%s)</p> <!-- %c --> </div> </body></html> 
\ No newline at end of file
diff -u -r -N squid-3.2.0.14/errors/sv/ERR_CONFLICT_HOST squid-3.2.0.15/errors/sv/ERR_CONFLICT_HOST
--- squid-3.2.0.14/errors/sv/ERR_CONFLICT_HOST	1970-01-01 12:00:00.000000000 +1200
+++ squid-3.2.0.15/errors/sv/ERR_CONFLICT_HOST	2012-02-06 05:53:29.000000000 +1300
@@ -0,0 +1 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html><head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8"> <title>FEL: Den beg&auml;rda URL:en kunde inte h&auml;mtas</title> <style type="text/css"><!--   %l  body :lang(fa) { direction: rtl; font-size: 100%; font-family: Tahoma, Roya, sans-serif; float: right; } :lang(he) { direction: rtl; }  --></style> </head><body id=%c> <div id="titles"> <h1>ERROR</h1> <h2>The requested URL could not be retrieved</h2> </div> <hr>  <div id="content"> <p>F&ouml;ljande fel p&aring;tr&auml;ffades vid h&auml;mtning av URL: <a href="%U">%U</a></p>  <blockquote id="data"> <pre>URI Host Conflict</pre> </blockquote>  <p>This means the domain name you are trying to access apparently no longer exists on the machine you are requesting it from.</p>  <p>N&aring;gra m&ouml;jliga problem &auml;r:</p> <ul> <li>The domain may have moved very recently. Trying again will resolve that.</li> <li>The website may require you to use a local country-based version. Using your ISP provided DNS server(s) should resolve that.</li> </ul>  <p>Din cacheserver administrat&ouml;r &auml;r <a href="mailto:%w%W">%w</a>.</p> <br> </div>  <hr> <div id="footer"> <p>Skapad %T av %h (%s)</p> <!-- %c --> </div> </body></html> 
\ No newline at end of file
diff -u -r -N squid-3.2.0.14/errors/template.list squid-3.2.0.15/errors/template.list
--- squid-3.2.0.14/errors/template.list	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/errors/template.list	2012-02-06 04:52:31.000000000 +1300
@@ -5,6 +5,7 @@
     templates/ERR_CACHE_ACCESS_DENIED \
     templates/ERR_CACHE_MGR_ACCESS_DENIED \
     templates/ERR_CANNOT_FORWARD \
+    templates/ERR_CONFLICT_HOST \
     templates/ERR_CONNECT_FAIL \
     templates/ERR_DIR_LISTING \
     templates/ERR_DNS_FAIL \
diff -u -r -N squid-3.2.0.14/errors/templates/ERR_CONFLICT_HOST squid-3.2.0.15/errors/templates/ERR_CONFLICT_HOST
--- squid-3.2.0.14/errors/templates/ERR_CONFLICT_HOST	1970-01-01 12:00:00.000000000 +1200
+++ squid-3.2.0.15/errors/templates/ERR_CONFLICT_HOST	2012-02-06 04:52:31.000000000 +1300
@@ -0,0 +1,43 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
+<html><head>
+<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
+<title>ERROR: The requested URL could not be retrieved</title>
+<style type="text/css"><!-- 
+ %l
+
+body
+:lang(fa) { direction: rtl; font-size: 100%; font-family: Tahoma, Roya, sans-serif; float: right; }
+:lang(he) { direction: rtl; }
+ --></style>
+</head><body id=%c>
+<div id="titles">
+<h1>ERROR</h1>
+<h2>The requested URL could not be retrieved</h2>
+</div>
+<hr>
+
+<div id="content">
+<p>The following error was encountered while trying to retrieve the URL: <a href="%U">%U</a></p>
+
+<blockquote id="data">
+<pre>URI Host Conflict</pre>
+</blockquote>
+
+<p>This means the domain name you are trying to access apparently no longer exists on the machine you are requesting it from.</p>
+
+<p>Some possible problems are:</p>
+<ul>
+<li>The domain may have moved very recently. Trying again will resolve that.</li>
+<li>The website may require you to use a local country-based version. Using your ISP provided DNS server(s) should resolve that.</li>
+</ul>
+
+<p>Your cache administrator is <a href="mailto:%w%W">%w</a>.</p>
+<br>
+</div>
+
+<hr>
+<div id="footer">
+<p>Generated %T by %h (%s)</p>
+<!-- %c -->
+</div>
+</body></html>
diff -u -r -N squid-3.2.0.14/errors/th/ERR_CONFLICT_HOST squid-3.2.0.15/errors/th/ERR_CONFLICT_HOST
--- squid-3.2.0.14/errors/th/ERR_CONFLICT_HOST	1970-01-01 12:00:00.000000000 +1200
+++ squid-3.2.0.15/errors/th/ERR_CONFLICT_HOST	2012-02-06 05:54:41.000000000 +1300
@@ -0,0 +1 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html><head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8"> <title>ERROR: ไม่สามารถเรียกดู URL ที่ได้รับการร้องขอ</title> <style type="text/css"><!--   %l  body :lang(fa) { direction: rtl; font-size: 100%; font-family: Tahoma, Roya, sans-serif; float: right; } :lang(he) { direction: rtl; }  --></style> </head><body id=%c> <div id="titles"> <h1>ERROR</h1> <h2>ไม่สามารถเรียกดู URL ที่ได้รับการร้องขอ</h2> </div> <hr>  <div id="content"> <p>พบความผิดพลาดดังต่อไปนี้ระหว่างที่พยายามเรียกดู URL: <a href="%U">%U</a></p>  <blockquote id="data"> <pre>URI Host Conflict</pre> </blockquote>  <p>This means the domain name you are trying to access apparently no longer exists on the machine you are requesting it from.</p>  <p>ปัญหาที่เป็นไปได้อาจจะเป็น:</p> <ul> <li>The domain may have moved very recently. Trying again will resolve that.</li> <li>The website may require you to use a local country-based version. Using your ISP provided DNS server(s) should resolve that.</li> </ul>  <p>ผู้ดูแลระบบแคชของคุณคือ <a href="mailto:%w%W">%w</a></p> <br> </div>  <hr> <div id="footer"> <p>Generated %T by %h (%s)</p> <!-- %c --> </div> </body></html> 
\ No newline at end of file
diff -u -r -N squid-3.2.0.14/errors/tr/ERR_CONFLICT_HOST squid-3.2.0.15/errors/tr/ERR_CONFLICT_HOST
--- squid-3.2.0.14/errors/tr/ERR_CONFLICT_HOST	1970-01-01 12:00:00.000000000 +1200
+++ squid-3.2.0.15/errors/tr/ERR_CONFLICT_HOST	2012-02-06 05:56:01.000000000 +1300
@@ -0,0 +1 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html><head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8"> <title>HATA: İstenilen URL'e ulaşılamadı</title> <style type="text/css"><!--   %l  body :lang(fa) { direction: rtl; font-size: 100%; font-family: Tahoma, Roya, sans-serif; float: right; } :lang(he) { direction: rtl; }  --></style> </head><body id=%c> <div id="titles"> <h1>ERROR</h1> <h2>The requested URL could not be retrieved</h2> </div> <hr>  <div id="content"> <p>URL adresine erişilmeye çalışıyorken hata meydana geldi: <a href="%U">%U</a></p>  <blockquote id="data"> <pre>URI Host Conflict</pre> </blockquote>  <p>This means the domain name you are trying to access apparently no longer exists on the machine you are requesting it from.</p>  <p>Buna sebep aşağidakilerden herhangi biri olabilir:</p> <ul> <li>The domain may have moved very recently. Trying again will resolve that.</li> <li>The website may require you to use a local country-based version. Using your ISP provided DNS server(s) should resolve that.</li> </ul>  <p>Önbellk yöneticiniz <a href="mailto:%w%W">%w</a>.</p> <br> </div>  <hr> <div id="footer"> <p>%h (%s) tarafından %T oluşturuldu</p> <!-- %c --> </div> </body></html> 
\ No newline at end of file
diff -u -r -N squid-3.2.0.14/errors/uk/ERR_CONFLICT_HOST squid-3.2.0.15/errors/uk/ERR_CONFLICT_HOST
--- squid-3.2.0.14/errors/uk/ERR_CONFLICT_HOST	1970-01-01 12:00:00.000000000 +1200
+++ squid-3.2.0.15/errors/uk/ERR_CONFLICT_HOST	2012-02-06 05:57:17.000000000 +1300
@@ -0,0 +1 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html><head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8"> <title>ПОМИЛКА: Запитаний URL не може бути отриманий.</title> <style type="text/css"><!--   %l  body :lang(fa) { direction: rtl; font-size: 100%; font-family: Tahoma, Roya, sans-serif; float: right; } :lang(he) { direction: rtl; }  --></style> </head><body id=%c> <div id="titles"> <h1>ERROR</h1> <h2>The requested URL could not be retrieved</h2> </div> <hr>  <div id="content"> <p>При отриманні URL: <a href="%U">%U</a> виникла помилка.</p>  <blockquote id="data"> <pre>URI Host Conflict</pre> </blockquote>  <p>This means the domain name you are trying to access apparently no longer exists on the machine you are requesting it from.</p>  <p>Ймовірні причини:</p> <ul> <li>The domain may have moved very recently. Trying again will resolve that.</li> <li>The website may require you to use a local country-based version. Using your ISP provided DNS server(s) should resolve that.</li> </ul>  <p>Адміністратор даного кешу <a href="mailto:%w%W">%w</a>.</p> <br> </div>  <hr> <div id="footer"> <p>Згенеровано %T на %h (%s)</p> <!-- %c --> </div> </body></html> 
\ No newline at end of file
diff -u -r -N squid-3.2.0.14/errors/uz/ERR_CONFLICT_HOST squid-3.2.0.15/errors/uz/ERR_CONFLICT_HOST
--- squid-3.2.0.14/errors/uz/ERR_CONFLICT_HOST	1970-01-01 12:00:00.000000000 +1200
+++ squid-3.2.0.15/errors/uz/ERR_CONFLICT_HOST	2012-02-06 05:58:21.000000000 +1300
@@ -0,0 +1 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html><head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8"> <title>ХАТО: Сўралган URL топилмади</title> <style type="text/css"><!--   %l  body :lang(fa) { direction: rtl; font-size: 100%; font-family: Tahoma, Roya, sans-serif; float: right; } :lang(he) { direction: rtl; }  --></style> </head><body id=%c> <div id="titles"> <h1>ERROR</h1> <h2>The requested URL could not be retrieved</h2> </div> <hr>  <div id="content"> <p>The following error was encountered while trying to retrieve the URL: <a href="%U">%U</a></p>  <blockquote id="data"> <pre>URI Host Conflict</pre> </blockquote>  <p>This means the domain name you are trying to access apparently no longer exists on the machine you are requesting it from.</p>  <p>Баъзи бўлиши мумкин бўлган муаммолар:</p> <ul> <li>The domain may have moved very recently. Trying again will resolve that.</li> <li>The website may require you to use a local country-based version. Using your ISP provided DNS server(s) should resolve that.</li> </ul>  <p>Your cache administrator is <a href="mailto:%w%W">%w</a>.</p> <br> </div>  <hr> <div id="footer"> <p>%h (%s) томонидан  %T яратилган</p> <!-- %c --> </div> </body></html> 
\ No newline at end of file
diff -u -r -N squid-3.2.0.14/errors/vi/ERR_CONFLICT_HOST squid-3.2.0.15/errors/vi/ERR_CONFLICT_HOST
--- squid-3.2.0.14/errors/vi/ERR_CONFLICT_HOST	1970-01-01 12:00:00.000000000 +1200
+++ squid-3.2.0.15/errors/vi/ERR_CONFLICT_HOST	2012-02-06 05:59:18.000000000 +1300
@@ -0,0 +1 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html><head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8"> <title>LỖI: The requested URL could not be retrieved</title> <style type="text/css"><!--   %l  body :lang(fa) { direction: rtl; font-size: 100%; font-family: Tahoma, Roya, sans-serif; float: right; } :lang(he) { direction: rtl; }  --></style> </head><body id=%c> <div id="titles"> <h1>ERROR</h1> <h2>The requested URL could not be retrieved</h2> </div> <hr>  <div id="content"> <p>The following error was encountered while trying to retrieve the URL: <a href="%U">%U</a></p>  <blockquote id="data"> <pre>URI Host Conflict</pre> </blockquote>  <p>This means the domain name you are trying to access apparently no longer exists on the machine you are requesting it from.</p>  <p>Một số vấn đề có thể gặp:</p> <ul> <li>The domain may have moved very recently. Trying again will resolve that.</li> <li>The website may require you to use a local country-based version. Using your ISP provided DNS server(s) should resolve that.</li> </ul>  <p>Your cache administrator is <a href="mailto:%w%W">%w</a>.</p> <br> </div>  <hr> <div id="footer"> <p>Tạo %T bởi %h (%s)</p> <!-- %c --> </div> </body></html> 
\ No newline at end of file
diff -u -r -N squid-3.2.0.14/errors/zh-cn/ERR_CONFLICT_HOST squid-3.2.0.15/errors/zh-cn/ERR_CONFLICT_HOST
--- squid-3.2.0.14/errors/zh-cn/ERR_CONFLICT_HOST	1970-01-01 12:00:00.000000000 +1200
+++ squid-3.2.0.15/errors/zh-cn/ERR_CONFLICT_HOST	2012-02-06 06:00:20.000000000 +1300
@@ -0,0 +1 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html><head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8"> <title>错误: 您所请求的网址（URL）无法获取</title> <style type="text/css"><!--   %l  body :lang(fa) { direction: rtl; font-size: 100%; font-family: Tahoma, Roya, sans-serif; float: right; } :lang(he) { direction: rtl; }  --></style> </head><body id=%c> <div id="titles"> <h1>ERROR</h1> <h2>The requested URL could not be retrieved</h2> </div> <hr>  <div id="content"> <p>当尝试取回该 URL 时遇到下面的错误：<a href="%U">%U</a></p>  <blockquote id="data"> <pre>URI Host Conflict</pre> </blockquote>  <p>This means the domain name you are trying to access apparently no longer exists on the machine you are requesting it from.</p>  <p>可能的问题包括：</p> <ul> <li>The domain may have moved very recently. Trying again will resolve that.</li> <li>The website may require you to use a local country-based version. Using your ISP provided DNS server(s) should resolve that.</li> </ul>  <p>缓存服务器的管理员 <a href="mailto:%w%W">%w</a>.</p> <br> </div>  <hr> <div id="footer"> <p>已由 %h (%s) 生成 %T</p> <!-- %c --> </div> </body></html> 
\ No newline at end of file
diff -u -r -N squid-3.2.0.14/errors/zh-tw/ERR_CONFLICT_HOST squid-3.2.0.15/errors/zh-tw/ERR_CONFLICT_HOST
--- squid-3.2.0.14/errors/zh-tw/ERR_CONFLICT_HOST	1970-01-01 12:00:00.000000000 +1200
+++ squid-3.2.0.15/errors/zh-tw/ERR_CONFLICT_HOST	2012-02-06 06:01:23.000000000 +1300
@@ -0,0 +1 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html><head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8"> <title>錯誤: 欲連結之網址（URL）無法正確的傳回</title> <style type="text/css"><!--   %l  body :lang(fa) { direction: rtl; font-size: 100%; font-family: Tahoma, Roya, sans-serif; float: right; } :lang(he) { direction: rtl; }  --></style> </head><body id=%c> <div id="titles"> <h1>ERROR</h1> <h2>The requested URL could not be retrieved</h2> </div> <hr>  <div id="content"> <p>The following error was encountered while trying to retrieve the URL: <a href="%U">%U</a></p>  <blockquote id="data"> <pre>URI Host Conflict</pre> </blockquote>  <p>This means the domain name you are trying to access apparently no longer exists on the machine you are requesting it from.</p>  <p>Some possible problems are:</p> <ul> <li>The domain may have moved very recently. Trying again will resolve that.</li> <li>The website may require you to use a local country-based version. Using your ISP provided DNS server(s) should resolve that.</li> </ul>  <p>Your cache administrator is <a href="mailto:%w%W">%w</a>.</p> <br> </div>  <hr> <div id="footer"> <p>Generated %T by %h (%s)</p> <!-- %c --> </div> </body></html> 
\ No newline at end of file
diff -u -r -N squid-3.2.0.14/helpers/basic_auth/DB/basic_db_auth.8 squid-3.2.0.15/helpers/basic_auth/DB/basic_db_auth.8
--- squid-3.2.0.14/helpers/basic_auth/DB/basic_db_auth.8	2011-12-13 01:28:59.000000000 +1300
+++ squid-3.2.0.15/helpers/basic_auth/DB/basic_db_auth.8	2012-02-06 06:02:19.000000000 +1300
@@ -124,7 +124,7 @@
 .\" ========================================================================
 .\"
 .IX Title "BASIC_DB_AUTH 1"
-.TH BASIC_DB_AUTH 1 "2011-12-12" "perl v5.10.1" "User Contributed Perl Documentation"
+.TH BASIC_DB_AUTH 1 "2012-02-05" "perl v5.10.1" "User Contributed Perl Documentation"
 .\" For nroff, turn off justification.  Always turn off hyphenation; it makes
 .\" way too many mistakes in technical documents.
 .if n .ad l
diff -u -r -N squid-3.2.0.14/helpers/basic_auth/fake/fake.cc squid-3.2.0.15/helpers/basic_auth/fake/fake.cc
--- squid-3.2.0.14/helpers/basic_auth/fake/fake.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/helpers/basic_auth/fake/fake.cc	2012-02-06 04:52:31.000000000 +1300
@@ -12,7 +12,7 @@
  * squid under the same conditions as the main squid application.
  */
 
-#include "config.h"
+#include "squid.h"
 #include "helpers/defines.h"
 
 #if HAVE_CSTRING
diff -u -r -N squid-3.2.0.14/helpers/basic_auth/getpwnam/basic_getpwnam_auth.cc squid-3.2.0.15/helpers/basic_auth/getpwnam/basic_getpwnam_auth.cc
--- squid-3.2.0.14/helpers/basic_auth/getpwnam/basic_getpwnam_auth.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/helpers/basic_auth/getpwnam/basic_getpwnam_auth.cc	2012-02-06 04:52:31.000000000 +1300
@@ -24,7 +24,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 #include "helpers/defines.h"
 #include "rfc1738.h"
 //#include "util.h"
diff -u -r -N squid-3.2.0.14/helpers/basic_auth/LDAP/basic_ldap_auth.cc squid-3.2.0.15/helpers/basic_auth/LDAP/basic_ldap_auth.cc
--- squid-3.2.0.14/helpers/basic_auth/LDAP/basic_ldap_auth.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/helpers/basic_auth/LDAP/basic_ldap_auth.cc	2012-02-06 04:52:31.000000000 +1300
@@ -82,7 +82,7 @@
  *             - Allow full filter specifications in -f
  */
 
-#include "config.h"
+#include "squid.h"
 
 #define LDAP_DEPRECATED 1
 
diff -u -r -N squid-3.2.0.14/helpers/basic_auth/MSNT/allowusers.cc squid-3.2.0.15/helpers/basic_auth/MSNT/allowusers.cc
--- squid-3.2.0.14/helpers/basic_auth/MSNT/allowusers.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/helpers/basic_auth/MSNT/allowusers.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "config.h"
+#include "squid.h"
 
 /*
  * allowusers.c
diff -u -r -N squid-3.2.0.14/helpers/basic_auth/MSNT/confload.cc squid-3.2.0.15/helpers/basic_auth/MSNT/confload.cc
--- squid-3.2.0.14/helpers/basic_auth/MSNT/confload.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/helpers/basic_auth/MSNT/confload.cc	2012-02-06 04:52:31.000000000 +1300
@@ -11,7 +11,7 @@
  */
 
 /* Squid provides a number of portability overrides */
-#include "config.h"
+#include "squid.h"
 
 #include <stdio.h>
 #include <stdlib.h>
diff -u -r -N squid-3.2.0.14/helpers/basic_auth/MSNT/denyusers.cc squid-3.2.0.15/helpers/basic_auth/MSNT/denyusers.cc
--- squid-3.2.0.14/helpers/basic_auth/MSNT/denyusers.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/helpers/basic_auth/MSNT/denyusers.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "config.h"
+#include "squid.h"
 
 /*
  * denyusers.c
diff -u -r -N squid-3.2.0.14/helpers/basic_auth/MSNT/msntauth.cc squid-3.2.0.15/helpers/basic_auth/MSNT/msntauth.cc
--- squid-3.2.0.14/helpers/basic_auth/MSNT/msntauth.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/helpers/basic_auth/MSNT/msntauth.cc	2012-02-06 04:52:31.000000000 +1300
@@ -29,7 +29,7 @@
  * along with this program; if not, write to the Free Software
  * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
  */
-#include "config.h"
+#include "squid.h"
 #include "rfc1738.h"
 #include "util.h"
 
diff -u -r -N squid-3.2.0.14/helpers/basic_auth/MSNT/usersfile.cc squid-3.2.0.15/helpers/basic_auth/MSNT/usersfile.cc
--- squid-3.2.0.14/helpers/basic_auth/MSNT/usersfile.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/helpers/basic_auth/MSNT/usersfile.cc	2012-02-06 04:52:31.000000000 +1300
@@ -8,7 +8,7 @@
  * The code originated from denyusers.c.
  */
 
-#include "config.h"
+#include "squid.h"
 #include "util.h"
 
 #include <stdio.h>
diff -u -r -N squid-3.2.0.14/helpers/basic_auth/MSNT/valid.cc squid-3.2.0.15/helpers/basic_auth/MSNT/valid.cc
--- squid-3.2.0.14/helpers/basic_auth/MSNT/valid.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/helpers/basic_auth/MSNT/valid.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "config.h"
+#include "squid.h"
 #if HAVE_SYS_TYPES_H
 #include <sys/types.h>
 #endif
diff -u -r -N squid-3.2.0.14/helpers/basic_auth/NCSA/basic_ncsa_auth.cc squid-3.2.0.15/helpers/basic_auth/NCSA/basic_ncsa_auth.cc
--- squid-3.2.0.14/helpers/basic_auth/NCSA/basic_ncsa_auth.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/helpers/basic_auth/NCSA/basic_ncsa_auth.cc	2012-02-06 04:52:31.000000000 +1300
@@ -16,7 +16,7 @@
  *  MD5 without salt and magic strings - Added by Ramon de Carvalho and Rodrigo Rubira Branco
  */
 
-#include "config.h"
+#include "squid.h"
 #include "crypt_md5.h"
 #include "hash.h"
 #include "helpers/defines.h"
diff -u -r -N squid-3.2.0.14/helpers/basic_auth/NCSA/crypt_md5.cc squid-3.2.0.15/helpers/basic_auth/NCSA/crypt_md5.cc
--- squid-3.2.0.14/helpers/basic_auth/NCSA/crypt_md5.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/helpers/basic_auth/NCSA/crypt_md5.cc	2012-02-06 04:52:31.000000000 +1300
@@ -14,7 +14,7 @@
  * Origin: Id: crypt.c,v 1.3 1995/05/30 05:42:22 rgrimes Exp
  *
  */
-#include "config.h"
+#include "squid.h"
 
 #if HAVE_STRING_H
 #include <string.h>
diff -u -r -N squid-3.2.0.14/helpers/basic_auth/NIS/basic_nis_auth.cc squid-3.2.0.15/helpers/basic_auth/NIS/basic_nis_auth.cc
--- squid-3.2.0.14/helpers/basic_auth/NIS/basic_nis_auth.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/helpers/basic_auth/NIS/basic_nis_auth.cc	2012-02-06 04:52:31.000000000 +1300
@@ -3,7 +3,7 @@
  * From NCSA Authentication module
  */
 
-#include "config.h"
+#include "squid.h"
 #include "hash.h"
 #include "nis_support.h"
 #include "rfc1738.h"
diff -u -r -N squid-3.2.0.14/helpers/basic_auth/NIS/nis_support.cc squid-3.2.0.15/helpers/basic_auth/NIS/nis_support.cc
--- squid-3.2.0.14/helpers/basic_auth/NIS/nis_support.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/helpers/basic_auth/NIS/nis_support.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,7 +1,7 @@
 /*
  * Written By Rabellino Sergio (rabellino@di.unito.it) For Solaris 2.x
  */
-#include "config.h"
+#include "squid.h"
 #include <stdlib.h>
 #include <stdio.h>
 #include <string.h>
diff -u -r -N squid-3.2.0.14/helpers/basic_auth/PAM/basic_pam_auth.cc squid-3.2.0.15/helpers/basic_auth/PAM/basic_pam_auth.cc
--- squid-3.2.0.14/helpers/basic_auth/PAM/basic_pam_auth.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/helpers/basic_auth/PAM/basic_pam_auth.cc	2012-02-06 04:52:31.000000000 +1300
@@ -65,7 +65,7 @@
  *
  * Compile this program with: gcc -o basic_pam_auth basic_pam_auth.cc -lpam -ldl
  */
-#include "config.h"
+#include "squid.h"
 #include "helpers/defines.h"
 #include "rfc1738.h"
 #include "util.h"
diff -u -r -N squid-3.2.0.14/helpers/basic_auth/RADIUS/basic_radius_auth.cc squid-3.2.0.15/helpers/basic_auth/RADIUS/basic_radius_auth.cc
--- squid-3.2.0.14/helpers/basic_auth/RADIUS/basic_radius_auth.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/helpers/basic_auth/RADIUS/basic_radius_auth.cc	2012-02-06 04:52:31.000000000 +1300
@@ -45,7 +45,7 @@
  * and many others
  */
 
-#include "config.h"
+#include "squid.h"
 #include "helpers/defines.h"
 #include "md5.h"
 #include "radius.h"
diff -u -r -N squid-3.2.0.14/helpers/basic_auth/RADIUS/radius-util.cc squid-3.2.0.15/helpers/basic_auth/RADIUS/radius-util.cc
--- squid-3.2.0.14/helpers/basic_auth/RADIUS/radius-util.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/helpers/basic_auth/RADIUS/radius-util.cc	2012-02-06 04:52:31.000000000 +1300
@@ -36,7 +36,7 @@
     "@(#)util.c	1.5 Copyright 1992 Livingston Enterprises Inc\n"
     "		2.1 Copyright 1997 Cistron Internet Services B.V.";
 
-#include "config.h"
+#include "squid.h"
 
 #if HAVE_SYS_SOCKET_H
 #include	<sys/socket.h>
diff -u -r -N squid-3.2.0.14/helpers/basic_auth/SASL/basic_sasl_auth.cc squid-3.2.0.15/helpers/basic_auth/SASL/basic_sasl_auth.cc
--- squid-3.2.0.14/helpers/basic_auth/SASL/basic_sasl_auth.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/helpers/basic_auth/SASL/basic_sasl_auth.cc	2012-02-06 04:52:31.000000000 +1300
@@ -26,7 +26,7 @@
  *             or with SASL2: gcc -Wall -o sasl_auth sasl_auth.c -lsasl2
  *
  */
-#include "config.h"
+#include "squid.h"
 #include "helpers/defines.h"
 #include "rfc1738.h"
 #include "util.h"
diff -u -r -N squid-3.2.0.14/helpers/basic_auth/SMB/basic_smb_auth.cc squid-3.2.0.15/helpers/basic_auth/SMB/basic_smb_auth.cc
--- squid-3.2.0.14/helpers/basic_auth/SMB/basic_smb_auth.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/helpers/basic_auth/SMB/basic_smb_auth.cc	2012-02-06 04:52:31.000000000 +1300
@@ -40,7 +40,7 @@
  *  along with this program; if not, write to the Free Software
  *  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111, USA.
  */
-#include "config.h"
+#include "squid.h"
 #include "helpers/defines.h"
 #include "rfc1738.h"
 #include "util.h"
diff -u -r -N squid-3.2.0.14/helpers/basic_auth/SSPI/basic_sspi_auth.cc squid-3.2.0.15/helpers/basic_auth/SSPI/basic_sspi_auth.cc
--- squid-3.2.0.14/helpers/basic_auth/SSPI/basic_sspi_auth.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/helpers/basic_auth/SSPI/basic_sspi_auth.cc	2012-02-06 04:52:31.000000000 +1300
@@ -24,7 +24,7 @@
  * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111, USA.
 */
 
-#include "config.h"
+#include "squid.h"
 #include "helpers/defines.h"
 #include "util.h"
 
diff -u -r -N squid-3.2.0.14/helpers/basic_auth/SSPI/valid.cc squid-3.2.0.15/helpers/basic_auth/SSPI/valid.cc
--- squid-3.2.0.14/helpers/basic_auth/SSPI/valid.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/helpers/basic_auth/SSPI/valid.cc	2012-02-06 04:52:31.000000000 +1300
@@ -26,7 +26,7 @@
  * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111, USA.
 */
 
-#include "config.h"
+#include "squid.h"
 #include "util.h"
 
 /* Check if we try to compile on a Windows Platform */
diff -u -r -N squid-3.2.0.14/helpers/digest_auth/eDirectory/digest_pw_auth.cc squid-3.2.0.15/helpers/digest_auth/eDirectory/digest_pw_auth.cc
--- squid-3.2.0.14/helpers/digest_auth/eDirectory/digest_pw_auth.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/helpers/digest_auth/eDirectory/digest_pw_auth.cc	2012-02-06 04:52:31.000000000 +1300
@@ -29,7 +29,7 @@
  *
  * Copyright (c) 2003  Robert Collins  <robertc@squid-cache.org>
  */
-#include "config.h"
+#include "squid.h"
 #include "digest_common.h"
 #include "helpers/defines.h"
 #include "ldap_backend.h"
diff -u -r -N squid-3.2.0.14/helpers/digest_auth/eDirectory/edir_ldapext.cc squid-3.2.0.15/helpers/digest_auth/eDirectory/edir_ldapext.cc
--- squid-3.2.0.14/helpers/digest_auth/eDirectory/edir_ldapext.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/helpers/digest_auth/eDirectory/edir_ldapext.cc	2012-02-06 04:52:31.000000000 +1300
@@ -22,7 +22,7 @@
  * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
  *
 */
-#include "config.h"
+#include "squid.h"
 
 #include "digest_common.h"
 
diff -u -r -N squid-3.2.0.14/helpers/digest_auth/eDirectory/ldap_backend.cc squid-3.2.0.15/helpers/digest_auth/eDirectory/ldap_backend.cc
--- squid-3.2.0.14/helpers/digest_auth/eDirectory/ldap_backend.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/helpers/digest_auth/eDirectory/ldap_backend.cc	2012-02-06 04:52:31.000000000 +1300
@@ -5,7 +5,7 @@
  * ldap_backend.c
  * AUTHOR: Flavio Pescuma, MARA Systems AB <flavio@marasystems.com>
  */
-#include "config.h"
+#include "squid.h"
 
 #define LDAP_DEPRECATED 1
 
diff -u -r -N squid-3.2.0.14/helpers/digest_auth/file/digest_file_auth.cc squid-3.2.0.15/helpers/digest_auth/file/digest_file_auth.cc
--- squid-3.2.0.14/helpers/digest_auth/file/digest_file_auth.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/helpers/digest_auth/file/digest_file_auth.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
  * Copyright (c) 2003  Robert Collins  <robertc@squid-cache.org>
  */
 
-#include "config.h"
+#include "squid.h"
 #include "digest_common.h"
 #include "helpers/defines.h"
 #include "text_backend.h"
diff -u -r -N squid-3.2.0.14/helpers/digest_auth/file/text_backend.cc squid-3.2.0.15/helpers/digest_auth/file/text_backend.cc
--- squid-3.2.0.14/helpers/digest_auth/file/text_backend.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/helpers/digest_auth/file/text_backend.cc	2012-02-06 04:52:31.000000000 +1300
@@ -28,7 +28,7 @@
  *
  * Copyright (c) 2003  Robert Collins  <robertc@squid-cache.org>
  */
-#include "config.h"
+#include "squid.h"
 
 #include "text_backend.h"
 
diff -u -r -N squid-3.2.0.14/helpers/digest_auth/LDAP/digest_pw_auth.cc squid-3.2.0.15/helpers/digest_auth/LDAP/digest_pw_auth.cc
--- squid-3.2.0.14/helpers/digest_auth/LDAP/digest_pw_auth.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/helpers/digest_auth/LDAP/digest_pw_auth.cc	2012-02-06 04:52:31.000000000 +1300
@@ -29,7 +29,7 @@
  *
  * Copyright (c) 2003  Robert Collins  <robertc@squid-cache.org>
  */
-#include "config.h"
+#include "squid.h"
 #include "digest_common.h"
 #include "helpers/defines.h"
 #include "ldap_backend.h"
diff -u -r -N squid-3.2.0.14/helpers/digest_auth/LDAP/ldap_backend.cc squid-3.2.0.15/helpers/digest_auth/LDAP/ldap_backend.cc
--- squid-3.2.0.14/helpers/digest_auth/LDAP/ldap_backend.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/helpers/digest_auth/LDAP/ldap_backend.cc	2012-02-06 04:52:31.000000000 +1300
@@ -5,7 +5,7 @@
  * ldap_backend.c
  * AUTHOR: Flavio Pescuma, MARA Systems AB <flavio@marasystems.com>
  */
-#include "config.h"
+#include "squid.h"
 #include "util.h"
 
 #define LDAP_DEPRECATED 1
diff -u -r -N squid-3.2.0.14/helpers/external_acl/AD_group/ext_ad_group_acl.cc squid-3.2.0.15/helpers/external_acl/AD_group/ext_ad_group_acl.cc
--- squid-3.2.0.14/helpers/external_acl/AD_group/ext_ad_group_acl.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/helpers/external_acl/AD_group/ext_ad_group_acl.cc	2012-02-06 04:52:31.000000000 +1300
@@ -57,7 +57,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 #include "helpers/defines.h"
 #include "include/util.h"
 
diff -u -r -N squid-3.2.0.14/helpers/external_acl/eDirectory_userip/ext_edirectory_userip_acl.cc squid-3.2.0.15/helpers/external_acl/eDirectory_userip/ext_edirectory_userip_acl.cc
--- squid-3.2.0.14/helpers/external_acl/eDirectory_userip/ext_edirectory_userip_acl.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/helpers/external_acl/eDirectory_userip/ext_edirectory_userip_acl.cc	2012-02-06 04:52:31.000000000 +1300
@@ -26,7 +26,7 @@
  */
 
 /* Squid-3.X includes */
-#include "config.h"
+#include "squid.h"
 #include "helpers/defines.h"
 #include "rfc1738.h"
 #include "util.h"
diff -u -r -N squid-3.2.0.14/helpers/external_acl/file_userip/ext_file_userip_acl.cc squid-3.2.0.15/helpers/external_acl/file_userip/ext_file_userip_acl.cc
--- squid-3.2.0.14/helpers/external_acl/file_userip/ext_file_userip_acl.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/helpers/external_acl/file_userip/ext_file_userip_acl.cc	2012-02-06 04:52:31.000000000 +1300
@@ -18,7 +18,7 @@
 * Author: Rodrigo Campos (rodrigo@geekbunker.org)
 *
 */
-#include "config.h"
+#include "squid.h"
 #include "helpers/defines.h"
 #include "rfc1738.h"
 #include "util.h"
diff -u -r -N squid-3.2.0.14/helpers/external_acl/kerberos_ldap_group/kerberos_ldap_group.cc squid-3.2.0.15/helpers/external_acl/kerberos_ldap_group/kerberos_ldap_group.cc
--- squid-3.2.0.14/helpers/external_acl/kerberos_ldap_group/kerberos_ldap_group.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/helpers/external_acl/kerberos_ldap_group/kerberos_ldap_group.cc	2012-02-06 04:52:31.000000000 +1300
@@ -29,7 +29,7 @@
 /*
  * Hosted at http://sourceforge.net/projects/squidkerbauth
  */
-#include "config.h"
+#include "squid.h"
 #include "helpers/defines.h"
 #include "util.h"
 
diff -u -r -N squid-3.2.0.14/helpers/external_acl/kerberos_ldap_group/support_group.cc squid-3.2.0.15/helpers/external_acl/kerberos_ldap_group/support_group.cc
--- squid-3.2.0.14/helpers/external_acl/kerberos_ldap_group/support_group.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/helpers/external_acl/kerberos_ldap_group/support_group.cc	2012-02-06 04:52:31.000000000 +1300
@@ -23,7 +23,7 @@
  * -----------------------------------------------------------------------------
  */
 
-#include "config.h"
+#include "squid.h"
 #include "util.h"
 
 #ifdef HAVE_LDAP
diff -u -r -N squid-3.2.0.14/helpers/external_acl/kerberos_ldap_group/support_krb5.cc squid-3.2.0.15/helpers/external_acl/kerberos_ldap_group/support_krb5.cc
--- squid-3.2.0.14/helpers/external_acl/kerberos_ldap_group/support_krb5.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/helpers/external_acl/kerberos_ldap_group/support_krb5.cc	2012-02-06 04:52:31.000000000 +1300
@@ -22,7 +22,7 @@
  * -----------------------------------------------------------------------------
  */
 
-#include "config.h"
+#include "squid.h"
 #include "util.h"
 
 #if defined(HAVE_LDAP) && defined(HAVE_KRB5)
diff -u -r -N squid-3.2.0.14/helpers/external_acl/kerberos_ldap_group/support_ldap.cc squid-3.2.0.15/helpers/external_acl/kerberos_ldap_group/support_ldap.cc
--- squid-3.2.0.14/helpers/external_acl/kerberos_ldap_group/support_ldap.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/helpers/external_acl/kerberos_ldap_group/support_ldap.cc	2012-02-06 04:52:31.000000000 +1300
@@ -22,7 +22,7 @@
  * -----------------------------------------------------------------------------
  */
 
-#include "config.h"
+#include "squid.h"
 #include "util.h"
 
 #ifdef HAVE_LDAP
diff -u -r -N squid-3.2.0.14/helpers/external_acl/kerberos_ldap_group/support_log.cc squid-3.2.0.15/helpers/external_acl/kerberos_ldap_group/support_log.cc
--- squid-3.2.0.14/helpers/external_acl/kerberos_ldap_group/support_log.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/helpers/external_acl/kerberos_ldap_group/support_log.cc	2012-02-06 04:52:31.000000000 +1300
@@ -22,7 +22,7 @@
  * -----------------------------------------------------------------------------
  */
 
-#include "config.h"
+#include "squid.h"
 
 #ifdef HAVE_LDAP
 
diff -u -r -N squid-3.2.0.14/helpers/external_acl/kerberos_ldap_group/support_lserver.cc squid-3.2.0.15/helpers/external_acl/kerberos_ldap_group/support_lserver.cc
--- squid-3.2.0.14/helpers/external_acl/kerberos_ldap_group/support_lserver.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/helpers/external_acl/kerberos_ldap_group/support_lserver.cc	2012-02-06 04:52:31.000000000 +1300
@@ -22,7 +22,7 @@
  * -----------------------------------------------------------------------------
  */
 
-#include "config.h"
+#include "squid.h"
 #include "util.h"
 
 #ifdef HAVE_LDAP
diff -u -r -N squid-3.2.0.14/helpers/external_acl/kerberos_ldap_group/support_member.cc squid-3.2.0.15/helpers/external_acl/kerberos_ldap_group/support_member.cc
--- squid-3.2.0.14/helpers/external_acl/kerberos_ldap_group/support_member.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/helpers/external_acl/kerberos_ldap_group/support_member.cc	2012-02-06 04:52:31.000000000 +1300
@@ -22,7 +22,7 @@
  * -----------------------------------------------------------------------------
  */
 
-#include "config.h"
+#include "squid.h"
 #include "util.h"
 
 #ifdef HAVE_LDAP
diff -u -r -N squid-3.2.0.14/helpers/external_acl/kerberos_ldap_group/support_netbios.cc squid-3.2.0.15/helpers/external_acl/kerberos_ldap_group/support_netbios.cc
--- squid-3.2.0.14/helpers/external_acl/kerberos_ldap_group/support_netbios.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/helpers/external_acl/kerberos_ldap_group/support_netbios.cc	2012-02-06 04:52:31.000000000 +1300
@@ -22,7 +22,7 @@
  * -----------------------------------------------------------------------------
  */
 
-#include "config.h"
+#include "squid.h"
 #include "util.h"
 
 #ifdef HAVE_LDAP
diff -u -r -N squid-3.2.0.14/helpers/external_acl/kerberos_ldap_group/support_resolv.cc squid-3.2.0.15/helpers/external_acl/kerberos_ldap_group/support_resolv.cc
--- squid-3.2.0.14/helpers/external_acl/kerberos_ldap_group/support_resolv.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/helpers/external_acl/kerberos_ldap_group/support_resolv.cc	2012-02-06 04:52:31.000000000 +1300
@@ -22,7 +22,7 @@
  * -----------------------------------------------------------------------------
  */
 
-#include "config.h"
+#include "squid.h"
 #include "util.h"
 
 #ifdef HAVE_LDAP
diff -u -r -N squid-3.2.0.14/helpers/external_acl/kerberos_ldap_group/support_sasl.cc squid-3.2.0.15/helpers/external_acl/kerberos_ldap_group/support_sasl.cc
--- squid-3.2.0.14/helpers/external_acl/kerberos_ldap_group/support_sasl.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/helpers/external_acl/kerberos_ldap_group/support_sasl.cc	2012-02-06 04:52:31.000000000 +1300
@@ -22,7 +22,7 @@
  * -----------------------------------------------------------------------------
  */
 
-#include "config.h"
+#include "squid.h"
 #include "util.h"
 
 #ifdef HAVE_LDAP
diff -u -r -N squid-3.2.0.14/helpers/external_acl/LDAP_group/ext_ldap_group_acl.cc squid-3.2.0.15/helpers/external_acl/LDAP_group/ext_ldap_group_acl.cc
--- squid-3.2.0.14/helpers/external_acl/LDAP_group/ext_ldap_group_acl.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/helpers/external_acl/LDAP_group/ext_ldap_group_acl.cc	2012-02-06 04:52:31.000000000 +1300
@@ -34,7 +34,7 @@
  * as published by the Free Software Foundation; either version 2,
  * or (at your option) any later version.
  */
-#include "config.h"
+#include "squid.h"
 #include "helpers/defines.h"
 #include "rfc1738.h"
 #include "util.h"
diff -u -r -N squid-3.2.0.14/helpers/external_acl/LM_group/ext_lm_group_acl.cc squid-3.2.0.15/helpers/external_acl/LM_group/ext_lm_group_acl.cc
--- squid-3.2.0.14/helpers/external_acl/LM_group/ext_lm_group_acl.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/helpers/external_acl/LM_group/ext_lm_group_acl.cc	2012-02-06 04:52:31.000000000 +1300
@@ -67,7 +67,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 #include "helpers/defines.h"
 #include "include/util.h"
 
diff -u -r -N squid-3.2.0.14/helpers/external_acl/session/ext_session_acl.cc squid-3.2.0.15/helpers/external_acl/session/ext_session_acl.cc
--- squid-3.2.0.14/helpers/external_acl/session/ext_session_acl.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/helpers/external_acl/session/ext_session_acl.cc	2012-02-06 04:52:31.000000000 +1300
@@ -19,7 +19,7 @@
  */
 
 #if HAVE_CONFIG_H
-#include "config.h"
+#include "squid.h"
 #endif
 #include "helpers/defines.h"
 
diff -u -r -N squid-3.2.0.14/helpers/external_acl/unix_group/check_group.cc squid-3.2.0.15/helpers/external_acl/unix_group/check_group.cc
--- squid-3.2.0.14/helpers/external_acl/unix_group/check_group.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/helpers/external_acl/unix_group/check_group.cc	2012-02-06 04:52:31.000000000 +1300
@@ -55,7 +55,7 @@
  * Initial revision
  *
  */
-#include "config.h"
+#include "squid.h"
 #include "helpers/defines.h"
 #include "rfc1738.h"
 #include "util.h"
@@ -80,7 +80,7 @@
 #endif
 
 /*
- * Verify if users primary group matches groupname
+ * Verify if user's primary group matches groupname
  * Returns 0 if user is not on the group
  * Returns 1 otherwise
  */
diff -u -r -N squid-3.2.0.14/helpers/external_acl/wbinfo_group/ext_wbinfo_group_acl.8 squid-3.2.0.15/helpers/external_acl/wbinfo_group/ext_wbinfo_group_acl.8
--- squid-3.2.0.14/helpers/external_acl/wbinfo_group/ext_wbinfo_group_acl.8	2011-12-13 01:29:07.000000000 +1300
+++ squid-3.2.0.15/helpers/external_acl/wbinfo_group/ext_wbinfo_group_acl.8	2012-02-06 06:02:27.000000000 +1300
@@ -124,7 +124,7 @@
 .\" ========================================================================
 .\"
 .IX Title "EXT_WBINFO_GROUP_ACL.PL.IN 1"
-.TH EXT_WBINFO_GROUP_ACL.PL.IN 1 "2011-12-12" "perl v5.10.1" "User Contributed Perl Documentation"
+.TH EXT_WBINFO_GROUP_ACL.PL.IN 1 "2012-02-05" "perl v5.10.1" "User Contributed Perl Documentation"
 .\" For nroff, turn off justification.  Always turn off hyphenation; it makes
 .\" way too many mistakes in technical documents.
 .if n .ad l
diff -u -r -N squid-3.2.0.14/helpers/log_daemon/file/log_file_daemon.cc squid-3.2.0.15/helpers/log_daemon/file/log_file_daemon.cc
--- squid-3.2.0.14/helpers/log_daemon/file/log_file_daemon.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/helpers/log_daemon/file/log_file_daemon.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "config.h"
+#include "squid.h"
 
 #if HAVE_STDIO_H
 #include <stdio.h>
diff -u -r -N squid-3.2.0.14/helpers/negotiate_auth/kerberos/negotiate_kerberos_auth.cc squid-3.2.0.15/helpers/negotiate_auth/kerberos/negotiate_kerberos_auth.cc
--- squid-3.2.0.14/helpers/negotiate_auth/kerberos/negotiate_kerberos_auth.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/helpers/negotiate_auth/kerberos/negotiate_kerberos_auth.cc	2012-02-06 04:52:31.000000000 +1300
@@ -29,7 +29,7 @@
 /*
  * Hosted at http://sourceforge.net/projects/squidkerbauth
  */
-#include "config.h"
+#include "squid.h"
 #include "compat/getaddrinfo.h"
 #include "compat/getnameinfo.h"
 
diff -u -r -N squid-3.2.0.14/helpers/negotiate_auth/kerberos/negotiate_kerberos_auth_test.cc squid-3.2.0.15/helpers/negotiate_auth/kerberos/negotiate_kerberos_auth_test.cc
--- squid-3.2.0.14/helpers/negotiate_auth/kerberos/negotiate_kerberos_auth_test.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/helpers/negotiate_auth/kerberos/negotiate_kerberos_auth_test.cc	2012-02-06 04:52:31.000000000 +1300
@@ -25,7 +25,7 @@
  * Hosted at http://sourceforge.net/projects/squidkerbauth
  */
 
-#include "config.h"
+#include "squid.h"
 
 #if HAVE_GSSAPI
 
diff -u -r -N squid-3.2.0.14/helpers/negotiate_auth/SSPI/negotiate_sspi_auth.cc squid-3.2.0.15/helpers/negotiate_auth/SSPI/negotiate_sspi_auth.cc
--- squid-3.2.0.14/helpers/negotiate_auth/SSPI/negotiate_sspi_auth.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/helpers/negotiate_auth/SSPI/negotiate_sspi_auth.cc	2012-02-06 04:52:31.000000000 +1300
@@ -36,7 +36,7 @@
  *
  *
  */
-#include "config.h"
+#include "squid.h"
 #include "helpers/defines.h"
 #include "libntlmauth/support_bits.cci"
 #include "sspwin32.h"
diff -u -r -N squid-3.2.0.14/helpers/negotiate_auth/wrapper/negotiate_wrapper.cc squid-3.2.0.15/helpers/negotiate_auth/wrapper/negotiate_wrapper.cc
--- squid-3.2.0.14/helpers/negotiate_auth/wrapper/negotiate_wrapper.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/helpers/negotiate_auth/wrapper/negotiate_wrapper.cc	2012-02-06 04:52:31.000000000 +1300
@@ -25,7 +25,7 @@
  * Hosted at http://sourceforge.net/projects/squidkerbauth
  */
 
-#include "config.h"
+#include "squid.h"
 #include "base64.h"
 
 #if HAVE_STRING_H
diff -u -r -N squid-3.2.0.14/helpers/ntlm_auth/fake/ntlm_fake_auth.cc squid-3.2.0.15/helpers/ntlm_auth/fake/ntlm_fake_auth.cc
--- squid-3.2.0.14/helpers/ntlm_auth/fake/ntlm_fake_auth.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/helpers/ntlm_auth/fake/ntlm_fake_auth.cc	2012-02-06 04:52:31.000000000 +1300
@@ -53,7 +53,7 @@
  * that though */
 #define IGNORANCE_IS_BLISS
 
-#include "config.h"
+#include "squid.h"
 #include "base64.h"
 #include "helpers/defines.h"
 #include "ntlmauth/ntlmauth.h"
diff -u -r -N squid-3.2.0.14/helpers/ntlm_auth/smb_lm/ntlm_smb_lm_auth.cc squid-3.2.0.15/helpers/ntlm_auth/smb_lm/ntlm_smb_lm_auth.cc
--- squid-3.2.0.14/helpers/ntlm_auth/smb_lm/ntlm_smb_lm_auth.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/helpers/ntlm_auth/smb_lm/ntlm_smb_lm_auth.cc	2012-02-06 04:52:31.000000000 +1300
@@ -13,7 +13,7 @@
  * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111, USA.
  *
  */
-#include "config.h"
+#include "squid.h"
 #include "base64.h"
 #include "compat/debug.h"
 #include "ntlmauth/ntlmauth.h"
diff -u -r -N squid-3.2.0.14/helpers/ntlm_auth/SSPI/ntlm_sspi_auth.cc squid-3.2.0.15/helpers/ntlm_auth/SSPI/ntlm_sspi_auth.cc
--- squid-3.2.0.14/helpers/ntlm_auth/SSPI/ntlm_sspi_auth.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/helpers/ntlm_auth/SSPI/ntlm_sspi_auth.cc	2012-02-06 04:52:31.000000000 +1300
@@ -63,7 +63,7 @@
 
 typedef unsigned char uchar;
 
-#include "config.h"
+#include "squid.h"
 #include "helpers/defines.h"
 #include "libntlmauth/ntlmauth.h"
 #include "libntlmauth/support_bits.h"
diff -u -r -N squid-3.2.0.14/helpers/url_rewrite/fake/fake.cc squid-3.2.0.15/helpers/url_rewrite/fake/fake.cc
--- squid-3.2.0.14/helpers/url_rewrite/fake/fake.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/helpers/url_rewrite/fake/fake.cc	2012-02-06 04:52:31.000000000 +1300
@@ -12,7 +12,7 @@
  * squid under the same conditions as the main squid application.
  */
 
-#include "config.h"
+#include "squid.h"
 #include "helpers/defines.h"
 
 #if HAVE_CSTRING
diff -u -r -N squid-3.2.0.14/include/autoconf.h.in squid-3.2.0.15/include/autoconf.h.in
--- squid-3.2.0.14/include/autoconf.h.in	2011-12-13 00:09:57.000000000 +1300
+++ squid-3.2.0.15/include/autoconf.h.in	2012-02-06 04:57:02.000000000 +1300
@@ -1240,7 +1240,7 @@
 #undef USE_DISKIO_IPCIO
 
 /* Use dnsserver processes instead of the internal DNS protocol support */
-#undef USE_DNSSERVERS
+#undef USE_DNSHELPER
 
 /* Disable eCAP support */
 #undef USE_ECAP
diff -u -r -N squid-3.2.0.14/include/config.h squid-3.2.0.15/include/config.h
--- squid-3.2.0.14/include/config.h	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/include/config.h	1970-01-01 12:00:00.000000000 +1200
@@ -1,119 +0,0 @@
-/*
- * $Id$
- *
- * AUTHOR: Duane Wessels
- *
- * SQUID Web Proxy Cache          http://www.squid-cache.org/
- * ----------------------------------------------------------
- *
- *  Squid is the result of efforts by numerous individuals from
- *  the Internet community; see the CONTRIBUTORS file for full
- *  details.   Many organizations have provided support for Squid's
- *  development; see the SPONSORS file for full details.  Squid is
- *  Copyrighted (C) 2001 by the Regents of the University of
- *  California; see the COPYRIGHT file for full details.  Squid
- *  incorporates software developed and/or copyrighted by other
- *  sources; see the CREDITS file for full details.
- *
- *  This program is free software; you can redistribute it and/or modify
- *  it under the terms of the GNU General Public License as published by
- *  the Free Software Foundation; either version 2 of the License, or
- *  (at your option) any later version.
- *
- *  This program is distributed in the hope that it will be useful,
- *  but WITHOUT ANY WARRANTY; without even the implied warranty of
- *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- *  GNU General Public License for more details.
- *
- *  You should have received a copy of the GNU General Public License
- *  along with this program; if not, write to the Free Software
- *  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111, USA.
- *
- */
-
-#ifndef SQUID_CONFIG_H
-#define SQUID_CONFIG_H
-
-#include "autoconf.h"		/* For GNU autoconf variables */
-
-#if !defined(HAVE_SQUID)
-/* sub-packages define their own version details */
-#include "version.h"
-
-#endif
-
-/* default values for listen ports. Usually specified in squid.conf really */
-#define CACHE_HTTP_PORT 3128
-#define CACHE_ICP_PORT 3130
-
-/* To keep API definitions clear */
-#ifdef __cplusplus
-#define SQUIDCEXTERN extern "C"
-#else
-#define SQUIDCEXTERN extern
-#endif
-
-#if _USE_INLINE_
-#define _SQUID_INLINE_ inline
-#else
-#define _SQUID_INLINE_
-#endif
-
-/****************************************************************************
- *--------------------------------------------------------------------------*
- * DO *NOT* MAKE ANY CHANGES below here unless you know what you're doing...*
- *--------------------------------------------------------------------------*
- ****************************************************************************/
-
-#include "compat/compat.h"
-
-#ifdef USE_POSIX_REGEX
-#ifndef USE_RE_SYNTAX
-#define USE_RE_SYNTAX	REG_EXTENDED	/* default Syntax */
-#endif
-#endif
-
-#if !defined(CACHEMGR_HOSTNAME)
-#define CACHEMGR_HOSTNAME ""
-#else
-#define CACHEMGR_HOSTNAME_DEFINED 1
-#endif
-
-#if SQUID_DETECT_UDP_SO_SNDBUF > 16384
-#define SQUID_UDP_SO_SNDBUF 16384
-#else
-#define SQUID_UDP_SO_SNDBUF SQUID_DETECT_UDP_SO_SNDBUF
-#endif
-
-#if SQUID_DETECT_UDP_SO_RCVBUF > 16384
-#define SQUID_UDP_SO_RCVBUF 16384
-#else
-#define SQUID_UDP_SO_RCVBUF SQUID_DETECT_UDP_SO_RCVBUF
-#endif
-
-#if HAVE_RANDOM
-#define squid_random random
-#define squid_srandom srandom
-#elif HAVE_LRAND48
-#define squid_random lrand48
-#define squid_srandom srand48
-#else
-#define squid_random rand
-#define squid_srandom srand
-#endif
-
-/*
- * Determine if this is a leak check build or standard
- */
-#if PURIFY
-#define LEAK_CHECK_MODE 1
-#elif WITH_VALGRIND
-#define LEAK_CHECK_MODE 1
-#elif XMALLOC_TRACE
-#define LEAK_CHECK_MODE 1
-#endif
-
-/* temp hack: needs to be pre-defined for now. */
-#define SQUID_MAXPATHLEN 256
-
-#endif /* SQUID_CONFIG_H */
diff -u -r -N squid-3.2.0.14/include/squid.h squid-3.2.0.15/include/squid.h
--- squid-3.2.0.14/include/squid.h	1970-01-01 12:00:00.000000000 +1200
+++ squid-3.2.0.15/include/squid.h	2012-02-06 04:52:31.000000000 +1300
@@ -0,0 +1,119 @@
+/*
+ * $Id$
+ *
+ * AUTHOR: Duane Wessels
+ *
+ * SQUID Web Proxy Cache          http://www.squid-cache.org/
+ * ----------------------------------------------------------
+ *
+ *  Squid is the result of efforts by numerous individuals from
+ *  the Internet community; see the CONTRIBUTORS file for full
+ *  details.   Many organizations have provided support for Squid's
+ *  development; see the SPONSORS file for full details.  Squid is
+ *  Copyrighted (C) 2001 by the Regents of the University of
+ *  California; see the COPYRIGHT file for full details.  Squid
+ *  incorporates software developed and/or copyrighted by other
+ *  sources; see the CREDITS file for full details.
+ *
+ *  This program is free software; you can redistribute it and/or modify
+ *  it under the terms of the GNU General Public License as published by
+ *  the Free Software Foundation; either version 2 of the License, or
+ *  (at your option) any later version.
+ *
+ *  This program is distributed in the hope that it will be useful,
+ *  but WITHOUT ANY WARRANTY; without even the implied warranty of
+ *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ *  GNU General Public License for more details.
+ *
+ *  You should have received a copy of the GNU General Public License
+ *  along with this program; if not, write to the Free Software
+ *  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111, USA.
+ *
+ */
+
+#ifndef SQUID_CONFIG_H
+#define SQUID_CONFIG_H
+
+#include "autoconf.h"		/* For GNU autoconf variables */
+
+#if !defined(HAVE_SQUID)
+/* sub-packages define their own version details */
+#include "version.h"
+
+#endif
+
+/* default values for listen ports. Usually specified in squid.conf really */
+#define CACHE_HTTP_PORT 3128
+#define CACHE_ICP_PORT 3130
+
+/* To keep API definitions clear */
+#ifdef __cplusplus
+#define SQUIDCEXTERN extern "C"
+#else
+#define SQUIDCEXTERN extern
+#endif
+
+#if _USE_INLINE_
+#define _SQUID_INLINE_ inline
+#else
+#define _SQUID_INLINE_
+#endif
+
+/****************************************************************************
+ *--------------------------------------------------------------------------*
+ * DO *NOT* MAKE ANY CHANGES below here unless you know what you're doing...*
+ *--------------------------------------------------------------------------*
+ ****************************************************************************/
+
+#include "compat/compat.h"
+
+#ifdef USE_POSIX_REGEX
+#ifndef USE_RE_SYNTAX
+#define USE_RE_SYNTAX	REG_EXTENDED	/* default Syntax */
+#endif
+#endif
+
+#if !defined(CACHEMGR_HOSTNAME)
+#define CACHEMGR_HOSTNAME ""
+#else
+#define CACHEMGR_HOSTNAME_DEFINED 1
+#endif
+
+#if SQUID_DETECT_UDP_SO_SNDBUF > 16384
+#define SQUID_UDP_SO_SNDBUF 16384
+#else
+#define SQUID_UDP_SO_SNDBUF SQUID_DETECT_UDP_SO_SNDBUF
+#endif
+
+#if SQUID_DETECT_UDP_SO_RCVBUF > 16384
+#define SQUID_UDP_SO_RCVBUF 16384
+#else
+#define SQUID_UDP_SO_RCVBUF SQUID_DETECT_UDP_SO_RCVBUF
+#endif
+
+#if HAVE_RANDOM
+#define squid_random random
+#define squid_srandom srandom
+#elif HAVE_LRAND48
+#define squid_random lrand48
+#define squid_srandom srand48
+#else
+#define squid_random rand
+#define squid_srandom srand
+#endif
+
+/*
+ * Determine if this is a leak check build or standard
+ */
+#if PURIFY
+#define LEAK_CHECK_MODE 1
+#elif WITH_VALGRIND
+#define LEAK_CHECK_MODE 1
+#elif XMALLOC_TRACE
+#define LEAK_CHECK_MODE 1
+#endif
+
+/* temp hack: needs to be pre-defined for now. */
+#define SQUID_MAXPATHLEN 256
+
+#endif /* SQUID_CONFIG_H */
diff -u -r -N squid-3.2.0.14/include/util.h squid-3.2.0.15/include/util.h
--- squid-3.2.0.14/include/util.h	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/include/util.h	2012-02-06 04:52:31.000000000 +1300
@@ -69,7 +69,6 @@
 #if XMALLOC_TRACE
 #define xmalloc(size) (xmalloc_func="xmalloc",xmalloc_line=__LINE__,xmalloc_file=__FILE__,xmalloc(size))
 #define xfree(ptr) (xmalloc_func="xfree",xmalloc_line=__LINE__,xmalloc_file=__FILE__,xfree(ptr))
-#define xxfree(ptr) (xmalloc_func="xxfree",xmalloc_line=__LINE__,xmalloc_file=__FILE__,xxfree(ptr))
 #define xrealloc(ptr,size) (xmalloc_func="xrealloc",xmalloc_line=__LINE__,xmalloc_file=__FILE__,xrealloc(ptr,size))
 #define xcalloc(n,size) (xmalloc_func="xcalloc",xmalloc_line=__LINE__,xmalloc_file=__FILE__,xcalloc(n,size))
 #define xstrdup(ptr) (xmalloc_func="xstrdup",xmalloc_line=__LINE__,xmalloc_file=__FILE__,xstrdup(ptr))
diff -u -r -N squid-3.2.0.14/include/version.h squid-3.2.0.15/include/version.h
--- squid-3.2.0.14/include/version.h	2011-12-13 00:11:47.000000000 +1300
+++ squid-3.2.0.15/include/version.h	2012-02-06 05:01:04.000000000 +1300
@@ -9,7 +9,7 @@
  */
 
 #ifndef SQUID_RELEASE_TIME
-#define SQUID_RELEASE_TIME 1323688094
+#define SQUID_RELEASE_TIME 1328457139
 #endif
 
 #ifndef APP_SHORTNAME
diff -u -r -N squid-3.2.0.14/lib/base64.c squid-3.2.0.15/lib/base64.c
--- squid-3.2.0.14/lib/base64.c	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/lib/base64.c	2012-02-06 04:52:31.000000000 +1300
@@ -6,7 +6,7 @@
  * Encoders adopted from http://ftp.sunet.se/pub2/gnu/vm/base64-encode.c with adjustments.
  */
 
-#include "config.h"
+#include "squid.h"
 #include "base64.h"
 
 #if HAVE_STDIO_H
diff -u -r -N squid-3.2.0.14/lib/charset.c squid-3.2.0.15/lib/charset.c
--- squid-3.2.0.14/lib/charset.c	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/lib/charset.c	2012-02-06 04:52:31.000000000 +1300
@@ -25,7 +25,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 #include "charset.h"
 
 /** Convert ISO-LATIN-1 to UTF-8 */
diff -u -r -N squid-3.2.0.14/lib/dirent.c squid-3.2.0.15/lib/dirent.c
--- squid-3.2.0.14/lib/dirent.c	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/lib/dirent.c	2012-02-06 04:52:31.000000000 +1300
@@ -48,7 +48,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 
 /* The following code section is part of the native Windows Squid port */
 #if _SQUID_MSWIN_
diff -u -r -N squid-3.2.0.14/lib/encrypt.c squid-3.2.0.15/lib/encrypt.c
--- squid-3.2.0.14/lib/encrypt.c	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/lib/encrypt.c	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "config.h"
+#include "squid.h"
 
 /* encrypt.c - providing 56 bit DES encryption
  * Copyright (C) 1991 Jochen Obalek
diff -u -r -N squid-3.2.0.14/lib/getfullhostname.c squid-3.2.0.15/lib/getfullhostname.c
--- squid-3.2.0.14/lib/getfullhostname.c	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/lib/getfullhostname.c	2012-02-06 04:52:31.000000000 +1300
@@ -31,7 +31,7 @@
  *  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111, USA.
  *
  */
-#include "config.h"
+#include "squid.h"
 #include "getfullhostname.h"
 
 
diff -u -r -N squid-3.2.0.14/lib/getopt.c squid-3.2.0.15/lib/getopt.c
--- squid-3.2.0.14/lib/getopt.c	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/lib/getopt.c	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "config.h"
+#include "squid.h"
 
 /*
  * Copyright (c) 1987, 1993, 1994
diff -u -r -N squid-3.2.0.14/lib/hash.c squid-3.2.0.15/lib/hash.c
--- squid-3.2.0.14/lib/hash.c	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/lib/hash.c	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 #include "hash.h"
 #include "profiler/Profiler.h"
 
diff -u -r -N squid-3.2.0.14/lib/heap.c squid-3.2.0.15/lib/heap.c
--- squid-3.2.0.14/lib/heap.c	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/lib/heap.c	2012-02-06 04:52:31.000000000 +1300
@@ -37,7 +37,7 @@
  * Copyright (C) 1999 by Hewlett Packard
  ****************************************************************************/
 
-#include "config.h"
+#include "squid.h"
 #include "heap.h"
 
 #if HAVE_STDLIB_H
diff -u -r -N squid-3.2.0.14/lib/html_quote.c squid-3.2.0.15/lib/html_quote.c
--- squid-3.2.0.14/lib/html_quote.c	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/lib/html_quote.c	2012-02-06 04:52:31.000000000 +1300
@@ -32,7 +32,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 #include "html_quote.h"
 
 #if HAVE_STDIO_H
diff -u -r -N squid-3.2.0.14/lib/iso3307.c squid-3.2.0.15/lib/iso3307.c
--- squid-3.2.0.14/lib/iso3307.c	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/lib/iso3307.c	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "config.h"
+#include "squid.h"
 #include "util.h"
 
 #if HAVE_STDIO_H
diff -u -r -N squid-3.2.0.14/lib/malloc_trace.cc squid-3.2.0.15/lib/malloc_trace.cc
--- squid-3.2.0.14/lib/malloc_trace.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/lib/malloc_trace.cc	2012-02-06 04:52:31.000000000 +1300
@@ -34,7 +34,7 @@
 
 #define _etext etext
 
-#include "config.h"
+#include "squid.h"
 #include "profiler/Profiler.h"
 #include "util.h"
 
@@ -98,7 +98,6 @@
 size_t xmalloc_total = 0;
 #undef xmalloc
 #undef xfree
-#undef xxfree
 #undef xrealloc
 #undef xcalloc
 #undef xstrdup
diff -u -r -N squid-3.2.0.14/lib/md5.c squid-3.2.0.15/lib/md5.c
--- squid-3.2.0.14/lib/md5.c	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/lib/md5.c	2012-02-06 04:52:31.000000000 +1300
@@ -29,7 +29,7 @@
  * Still in the public domain.
  *
  */
-#include "config.h"
+#include "squid.h"
 #include "md5.h"
 
 #if HAVE_STRING_H
diff -u -r -N squid-3.2.0.14/lib/MemPool.cc squid-3.2.0.15/lib/MemPool.cc
--- squid-3.2.0.14/lib/MemPool.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/lib/MemPool.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 #if HAVE_ASSERT_H
 #include <assert.h>
 #endif
diff -u -r -N squid-3.2.0.14/lib/MemPoolChunked.cc squid-3.2.0.15/lib/MemPoolChunked.cc
--- squid-3.2.0.14/lib/MemPoolChunked.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/lib/MemPoolChunked.cc	2012-02-06 04:52:31.000000000 +1300
@@ -81,7 +81,7 @@
  *   Copyright (c) 2003, Robert Collins <robertc@squid-cache.org>
  */
 
-#include "config.h"
+#include "squid.h"
 #if HAVE_ASSERT_H
 #include <assert.h>
 #endif
diff -u -r -N squid-3.2.0.14/lib/MemPoolMalloc.cc squid-3.2.0.15/lib/MemPoolMalloc.cc
--- squid-3.2.0.14/lib/MemPoolMalloc.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/lib/MemPoolMalloc.cc	2012-02-06 04:52:31.000000000 +1300
@@ -34,7 +34,7 @@
  */
 
 
-#include "config.h"
+#include "squid.h"
 #if HAVE_ASSERT_H
 #include <assert.h>
 #endif
diff -u -r -N squid-3.2.0.14/lib/ntlmauth/ntlmauth.cc squid-3.2.0.15/lib/ntlmauth/ntlmauth.cc
--- squid-3.2.0.14/lib/ntlmauth/ntlmauth.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/lib/ntlmauth/ntlmauth.cc	2012-02-06 04:52:31.000000000 +1300
@@ -25,7 +25,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 
 #if HAVE_STRING_H
 #include <string.h>
diff -u -r -N squid-3.2.0.14/lib/profiler/Profiler.cc squid-3.2.0.15/lib/profiler/Profiler.cc
--- squid-3.2.0.14/lib/profiler/Profiler.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/lib/profiler/Profiler.cc	2012-02-06 04:52:31.000000000 +1300
@@ -113,7 +113,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 #include "profiler/Profiler.h"
 
 #if USE_XPROF_STATS
diff -u -r -N squid-3.2.0.14/lib/radix.c squid-3.2.0.15/lib/radix.c
--- squid-3.2.0.14/lib/radix.c	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/lib/radix.c	2012-02-06 04:52:31.000000000 +1300
@@ -64,7 +64,7 @@
  *      @(#)radix.c     8.4 (Berkeley) 11/2/94
  */
 
-#include "config.h"
+#include "squid.h"
 #include "radix.h"
 #include "util.h"
 
diff -u -r -N squid-3.2.0.14/lib/rfc1035.c squid-3.2.0.15/lib/rfc1035.c
--- squid-3.2.0.14/lib/rfc1035.c	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/lib/rfc1035.c	2012-02-06 04:52:31.000000000 +1300
@@ -38,7 +38,7 @@
  * UDP replies with TC set should be retried via TCP
  */
 
-#include "config.h"
+#include "squid.h"
 #include "util.h"
 
 #if HAVE_STDIO_H
diff -u -r -N squid-3.2.0.14/lib/rfc1123.c squid-3.2.0.15/lib/rfc1123.c
--- squid-3.2.0.14/lib/rfc1123.c	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/lib/rfc1123.c	2012-02-06 04:52:31.000000000 +1300
@@ -32,7 +32,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 #include "rfc1123.h"
 
 /*
diff -u -r -N squid-3.2.0.14/lib/rfc1738.c squid-3.2.0.15/lib/rfc1738.c
--- squid-3.2.0.14/lib/rfc1738.c	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/lib/rfc1738.c	2012-02-06 04:52:31.000000000 +1300
@@ -32,7 +32,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 #include "rfc1738.h"
 
 #if HAVE_STDIO_H
diff -u -r -N squid-3.2.0.14/lib/rfc2617.c squid-3.2.0.15/lib/rfc2617.c
--- squid-3.2.0.14/lib/rfc2617.c	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/lib/rfc2617.c	2012-02-06 04:52:31.000000000 +1300
@@ -46,7 +46,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 #include <string.h>
 #include "rfc2617.h"
 #include "md5.h"
diff -u -r -N squid-3.2.0.14/lib/rfc2671.c squid-3.2.0.15/lib/rfc2671.c
--- squid-3.2.0.14/lib/rfc2671.c	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/lib/rfc2671.c	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "config.h"
+#include "squid.h"
 #include "rfc2671.h"
 #include "rfc1035.h"
 
diff -u -r -N squid-3.2.0.14/lib/rfc3596.c squid-3.2.0.15/lib/rfc3596.c
--- squid-3.2.0.14/lib/rfc3596.c	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/lib/rfc3596.c	2012-02-06 04:52:31.000000000 +1300
@@ -55,7 +55,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 #include "compat/inet_pton.h"
 #include "util.h"
 
diff -u -r -N squid-3.2.0.14/lib/rfcnb/rfcnb-io.c squid-3.2.0.15/lib/rfcnb/rfcnb-io.c
--- squid-3.2.0.14/lib/rfcnb/rfcnb-io.c	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/lib/rfcnb/rfcnb-io.c	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "config.h"
+#include "squid.h"
 
 /* UNIX RFCNB (RFC1001/RFC1002) NEtBIOS implementation
  *
diff -u -r -N squid-3.2.0.14/lib/rfcnb/rfcnb-util.c squid-3.2.0.15/lib/rfcnb/rfcnb-util.c
--- squid-3.2.0.14/lib/rfcnb/rfcnb-util.c	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/lib/rfcnb/rfcnb-util.c	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "config.h"
+#include "squid.h"
 
 /* UNIX RFCNB (RFC1001/RFC1002) NetBIOS implementation
  *
diff -u -r -N squid-3.2.0.14/lib/rfcnb/session.c squid-3.2.0.15/lib/rfcnb/session.c
--- squid-3.2.0.14/lib/rfcnb/session.c	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/lib/rfcnb/session.c	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "config.h"
+#include "squid.h"
 
 /* UNIX RFCNB (RFC1001/RFC1002) NetBIOS implementation
  *
diff -u -r -N squid-3.2.0.14/lib/smblib/md4.c squid-3.2.0.15/lib/smblib/md4.c
--- squid-3.2.0.14/lib/smblib/md4.c	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/lib/smblib/md4.c	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "config.h"
+#include "squid.h"
 
 /*
  * Unix SMB/Netbios implementation.
diff -u -r -N squid-3.2.0.14/lib/smblib/smbdes.c squid-3.2.0.15/lib/smblib/smbdes.c
--- squid-3.2.0.14/lib/smblib/smbdes.c	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/lib/smblib/smbdes.c	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "config.h"
+#include "squid.h"
 
 /*
  * Unix SMB/Netbios implementation.
diff -u -r -N squid-3.2.0.14/lib/smblib/smbencrypt.c squid-3.2.0.15/lib/smblib/smbencrypt.c
--- squid-3.2.0.14/lib/smblib/smbencrypt.c	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/lib/smblib/smbencrypt.c	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "config.h"
+#include "squid.h"
 
 /*
  * Unix SMB/Netbios implementation.
diff -u -r -N squid-3.2.0.14/lib/smblib/smblib.c squid-3.2.0.15/lib/smblib/smblib.c
--- squid-3.2.0.14/lib/smblib/smblib.c	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/lib/smblib/smblib.c	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "config.h"
+#include "squid.h"
 
 /* UNIX SMBlib NetBIOS implementation
 
diff -u -r -N squid-3.2.0.14/lib/smblib/smblib-util.c squid-3.2.0.15/lib/smblib/smblib-util.c
--- squid-3.2.0.14/lib/smblib/smblib-util.c	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/lib/smblib/smblib-util.c	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "config.h"
+#include "squid.h"
 
 /* UNIX SMBlib NetBIOS implementation
 
diff -u -r -N squid-3.2.0.14/lib/Splay.cc squid-3.2.0.15/lib/Splay.cc
--- squid-3.2.0.14/lib/Splay.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/lib/Splay.cc	2012-02-06 04:52:31.000000000 +1300
@@ -5,7 +5,7 @@
  * http://bobo.link.cs.cmu.edu/cgi-bin/splay/splay-cgi.pl
  */
 
-#include "config.h"
+#include "squid.h"
 
 #if HAVE_STDIO_H
 #include <stdio.h>
diff -u -r -N squid-3.2.0.14/lib/sspwin32.c squid-3.2.0.15/lib/sspwin32.c
--- squid-3.2.0.14/lib/sspwin32.c	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/lib/sspwin32.c	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 #include "util.h"
 
 #include "libntlmauth/ntlmauth.h"
diff -u -r -N squid-3.2.0.14/lib/stub_memaccount.c squid-3.2.0.15/lib/stub_memaccount.c
--- squid-3.2.0.14/lib/stub_memaccount.c	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/lib/stub_memaccount.c	2012-02-06 04:52:31.000000000 +1300
@@ -3,7 +3,7 @@
  */
 
 /* Stub function for programs not implementing statMemoryAccounted */
-#include "config.h"
+#include "squid.h"
 #include "util.h"
 int
 statMemoryAccounted(void)
diff -u -r -N squid-3.2.0.14/lib/tests/testArray.cc squid-3.2.0.15/lib/tests/testArray.cc
--- squid-3.2.0.14/lib/tests/testArray.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/lib/tests/testArray.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,5 +1,5 @@
 #define SQUID_UNIT_TEST 1
-#include "config.h"
+#include "squid.h"
 
 #if HAVE_ASSERT_H
 #include <assert.h>
diff -u -r -N squid-3.2.0.14/lib/tests/testMain.cc squid-3.2.0.15/lib/tests/testMain.cc
--- squid-3.2.0.14/lib/tests/testMain.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/lib/tests/testMain.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "config.h"
+#include "squid.h"
 
 #include <cppunit/BriefTestProgressListener.h>
 #include <cppunit/CompilerOutputter.h>
diff -u -r -N squid-3.2.0.14/lib/tests/testRFC1035.cc squid-3.2.0.15/lib/tests/testRFC1035.cc
--- squid-3.2.0.14/lib/tests/testRFC1035.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/lib/tests/testRFC1035.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,5 +1,5 @@
 #define SQUID_UNIT_TEST 1
-#include "config.h"
+#include "squid.h"
 
 #if HAVE_ASSERT_H
 #include <assert.h>
diff -u -r -N squid-3.2.0.14/lib/tests/testRFC1738.cc squid-3.2.0.15/lib/tests/testRFC1738.cc
--- squid-3.2.0.14/lib/tests/testRFC1738.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/lib/tests/testRFC1738.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,5 +1,5 @@
 #define SQUID_UNIT_TEST 1
-#include "config.h"
+#include "squid.h"
 
 #if HAVE_ASSERT_H
 #include <assert.h>
diff -u -r -N squid-3.2.0.14/lib/util.c squid-3.2.0.15/lib/util.c
--- squid-3.2.0.14/lib/util.c	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/lib/util.c	2012-02-06 04:52:31.000000000 +1300
@@ -34,7 +34,7 @@
 
 #define _etext etext
 
-#include "config.h"
+#include "squid.h"
 #include "profiler/Profiler.h"
 #include "util.h"
 
diff -u -r -N squid-3.2.0.14/lib/uudecode.c squid-3.2.0.15/lib/uudecode.c
--- squid-3.2.0.14/lib/uudecode.c	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/lib/uudecode.c	2012-02-06 04:52:31.000000000 +1300
@@ -2,7 +2,7 @@
  * $Id$
  */
 
-#include "config.h"
+#include "squid.h"
 #include "uudecode.h"
 
 /* aaaack but it's fast and const should make it shared text page. */
diff -u -r -N squid-3.2.0.14/lib/xusleep.c squid-3.2.0.15/lib/xusleep.c
--- squid-3.2.0.14/lib/xusleep.c	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/lib/xusleep.c	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "config.h"
+#include "squid.h"
 #include "profiler/Profiler.h"
 #include "xusleep.h"
 
diff -u -r -N squid-3.2.0.14/RELEASENOTES.html squid-3.2.0.15/RELEASENOTES.html
--- squid-3.2.0.14/RELEASENOTES.html	2011-12-13 01:29:38.000000000 +1300
+++ squid-3.2.0.15/RELEASENOTES.html	2012-02-06 06:03:01.000000000 +1300
@@ -2,10 +2,10 @@
 <HTML>
 <HEAD>
  <META NAME="GENERATOR" CONTENT="LinuxDoc-Tools 0.9.66">
- <TITLE>Squid 3.2.0.14 release notes</TITLE>
+ <TITLE>Squid 3.2.0.15 release notes</TITLE>
 </HEAD>
 <BODY>
-<H1>Squid 3.2.0.14 release notes</H1>
+<H1>Squid 3.2.0.15 release notes</H1>
 
 <H2>Squid Developers</H2>
 <HR>
@@ -72,7 +72,7 @@
 <HR>
 <H2><A NAME="s1">1.</A> <A HREF="#toc1">Notice</A></H2>
 
-<P>The Squid Team are pleased to announce the release of Squid-3.2.0.14 for testing.</P>
+<P>The Squid Team are pleased to announce the release of Squid-3.2.0.15 for testing.</P>
 <P>This new release is available for download from 
 <A HREF="http://www.squid-cache.org/Versions/v3/3.2/">http://www.squid-cache.org/Versions/v3/3.2/</A> or the 
 <A HREF="http://www.squid-cache.org/Mirrors/http-mirrors.html">mirrors</A>.</P>
@@ -479,6 +479,16 @@
 </PRE>
 </P>
 
+<P>The manager prefix /squid-internal-mgr/ with no action attempts to load an optional
+template MGR_INDEX which may be installed amongst in the Squid error templates.
+This template is not supplied with Squid but intended to be supplied by separate
+cache manager applications as their front page embedding all scripts, accessors or
+redirects required for their initial GUI display.</P>
+
+<P>Version 3.2 of the CGI cache manager tool now presents XHR scripted probes to detect
+proxies presenting these manager index pagess and provides direct HTTP/HTTPS web links
+to those managers.</P>
+
 
 <H2><A NAME="s3">3.</A> <A HREF="#toc3">Changes to squid.conf since Squid-3.1</A></H2>
 
@@ -594,6 +604,10 @@
 </PRE>
 </P>
 
+<DT><B>memory_cache_shared</B><DD>
+<P>Controls whether the memory cache is shared among SMP workers.</P>
+<P>Currently, entities exceeding 32KB in size cannot be shared.</P>
+
 <DT><B>server_idle_pconn_timeout</B><DD>
 <P>Renamed from <EM>pconn_timeout</EM>.</P>
 
@@ -675,6 +689,9 @@
 3xx status only available when redirecting to a URI.
 Other status only available when supplying an error template body.</P>
 
+<DT><B>dns_v4_fallback</B><DD>
+<P>Obsoleted by DNS parallel lookups.</P>
+
 <DT><B>external_acl_type</B><DD>
 <P>New format tags and option parameters:</P>
 <P><EM>%SRCEUI48</EM> EUI-48 / MAC address of client from ARP lookup.</P>
diff -u -r -N squid-3.2.0.14/snmplib/asn1.c squid-3.2.0.15/snmplib/asn1.c
--- squid-3.2.0.14/snmplib/asn1.c	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/snmplib/asn1.c	2012-02-06 04:52:31.000000000 +1300
@@ -31,7 +31,7 @@
  *
  ***************************************************************************/
 
-#include "config.h"
+#include "squid.h"
 
 #include <stdio.h>
 
diff -u -r -N squid-3.2.0.14/snmplib/coexistance.c squid-3.2.0.15/snmplib/coexistance.c
--- squid-3.2.0.14/snmplib/coexistance.c	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/snmplib/coexistance.c	2012-02-06 04:52:31.000000000 +1300
@@ -27,9 +27,7 @@
  *
  **********************************************************************/
 
-#include "config.h"
-
-#include "config.h"
+#include "squid.h"
 
 #include <stdio.h>
 
diff -u -r -N squid-3.2.0.14/snmplib/mib.c squid-3.2.0.15/snmplib/mib.c
--- squid-3.2.0.14/snmplib/mib.c	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/snmplib/mib.c	2012-02-06 04:52:31.000000000 +1300
@@ -22,7 +22,7 @@
 ******************************************************************/
 
 #define SQUID_NO_STRING_BUFFER_PROTECT 1
-#include "config.h"
+#include "squid.h"
 
 #include <stdio.h>
 
diff -u -r -N squid-3.2.0.14/snmplib/parse.c squid-3.2.0.15/snmplib/parse.c
--- squid-3.2.0.14/snmplib/parse.c	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/snmplib/parse.c	2012-02-06 04:52:31.000000000 +1300
@@ -23,7 +23,7 @@
 /*
  * parse.c
  */
-#include "config.h"
+#include "squid.h"
 
 #include <stdio.h>
 
diff -u -r -N squid-3.2.0.14/snmplib/snmp_api.c squid-3.2.0.15/snmplib/snmp_api.c
--- squid-3.2.0.14/snmplib/snmp_api.c	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/snmplib/snmp_api.c	2012-02-06 04:52:31.000000000 +1300
@@ -24,7 +24,7 @@
  *
  **********************************************************************/
 
-#include "config.h"
+#include "squid.h"
 
 #include <stdio.h>
 
diff -u -r -N squid-3.2.0.14/snmplib/snmp_api_error.c squid-3.2.0.15/snmplib/snmp_api_error.c
--- squid-3.2.0.14/snmplib/snmp_api_error.c	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/snmplib/snmp_api_error.c	2012-02-06 04:52:31.000000000 +1300
@@ -30,9 +30,7 @@
  *
  ***************************************************************************/
 
-#if HAVE_CONFIG_H
-#include "config.h"
-#endif /* HAVE_CONFIG_H */
+#include "squid.h"
 
 #include <stdio.h>
 #include "snmp_api_error.h"
diff -u -r -N squid-3.2.0.14/snmplib/snmp_error.c squid-3.2.0.15/snmplib/snmp_error.c
--- squid-3.2.0.14/snmplib/snmp_error.c	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/snmplib/snmp_error.c	2012-02-06 04:52:31.000000000 +1300
@@ -26,7 +26,7 @@
  *
  **********************************************************************/
 
-#include "config.h"
+#include "squid.h"
 
 #include <stdio.h>
 
diff -u -r -N squid-3.2.0.14/snmplib/snmplib_debug.c squid-3.2.0.15/snmplib/snmplib_debug.c
--- squid-3.2.0.14/snmplib/snmplib_debug.c	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/snmplib/snmplib_debug.c	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "config.h"
+#include "squid.h"
 #if HAVE_STDIO_H
 #include <stdio.h>
 #endif
diff -u -r -N squid-3.2.0.14/snmplib/snmp_msg.c squid-3.2.0.15/snmplib/snmp_msg.c
--- squid-3.2.0.14/snmplib/snmp_msg.c	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/snmplib/snmp_msg.c	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
  *
  **********************************************************************/
 
-#include "config.h"
+#include "squid.h"
 
 #include <stdio.h>
 
diff -u -r -N squid-3.2.0.14/snmplib/snmp_pdu.c squid-3.2.0.15/snmplib/snmp_pdu.c
--- squid-3.2.0.14/snmplib/snmp_pdu.c	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/snmplib/snmp_pdu.c	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
  *
  **********************************************************************/
 
-#include "config.h"
+#include "squid.h"
 
 #include <stdio.h>
 
diff -u -r -N squid-3.2.0.14/snmplib/snmp_vars.c squid-3.2.0.15/snmplib/snmp_vars.c
--- squid-3.2.0.14/snmplib/snmp_vars.c	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/snmplib/snmp_vars.c	2012-02-06 04:52:31.000000000 +1300
@@ -32,7 +32,7 @@
  *
  **********************************************************************/
 
-#include "config.h"
+#include "squid.h"
 
 #include <stdio.h>
 
diff -u -r -N squid-3.2.0.14/src/AccessLogEntry.cc squid-3.2.0.15/src/AccessLogEntry.cc
--- squid-3.2.0.14/src/AccessLogEntry.cc	1970-01-01 12:00:00.000000000 +1200
+++ squid-3.2.0.15/src/AccessLogEntry.cc	2012-02-06 04:52:31.000000000 +1300
@@ -0,0 +1,19 @@
+#include "squid.h"
+#include "AccessLogEntry.h"
+#include "HttpRequest.h"
+
+void
+AccessLogEntry::getLogClientIp(char *buf, size_t bufsz) const
+{
+#if FOLLOW_X_FORWARDED_FOR
+    if (Config.onoff.log_uses_indirect_client && request)
+        request->indirect_client_addr.NtoA(buf, bufsz);
+    else
+#endif
+        if (tcpClient != NULL)
+            tcpClient->remote.NtoA(buf, bufsz);
+        else if (cache.caddr.IsNoAddr()) // e.g., ICAP OPTIONS lack client
+            strncpy(buf, "-", 1);
+        else
+            cache.caddr.NtoA(buf, bufsz);
+}
diff -u -r -N squid-3.2.0.14/src/AccessLogEntry.h squid-3.2.0.15/src/AccessLogEntry.h
--- squid-3.2.0.14/src/AccessLogEntry.h	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/AccessLogEntry.h	2012-02-06 04:52:31.000000000 +1300
@@ -52,6 +52,11 @@
     AccessLogEntry() : url(NULL), tcpClient(), reply(NULL), request(NULL),
             adapted_request(NULL) {}
 
+    /// Fetch the client IP log string into the given buffer.
+    /// Knows about several alternate locations of the IP
+    /// including indirect forwarded-for IP if configured to log that
+    void getLogClientIp(char *buf, size_t bufsz) const;
+
     const char *url;
 
     /// TCP/IP level details about the client connection
diff -u -r -N squid-3.2.0.14/src/acl/Acl.cc squid-3.2.0.15/src/acl/Acl.cc
--- squid-3.2.0.14/src/acl/Acl.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/acl/Acl.cc	2012-02-06 04:52:31.000000000 +1300
@@ -31,7 +31,7 @@
  *  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111, USA.
  *
  */
-#include "config.h"
+#include "squid.h"
 
 #include "acl/Acl.h"
 #include "acl/Checklist.h"
diff -u -r -N squid-3.2.0.14/src/acl/Arp.cc squid-3.2.0.15/src/acl/Arp.cc
--- squid-3.2.0.14/src/acl/Arp.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/acl/Arp.cc	2012-02-06 04:52:31.000000000 +1300
@@ -32,7 +32,7 @@
  * Copyright (c) 2003, Robert Collins <robertc@squid-cache.org>
  */
 
-#include "squid.h"
+#include "squid-old.h"
 
 #if USE_SQUID_EUI
 
diff -u -r -N squid-3.2.0.14/src/acl/Asn.cc squid-3.2.0.15/src/acl/Asn.cc
--- squid-3.2.0.14/src/acl/Asn.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/acl/Asn.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "mgr/Registration.h"
 #include "radix.h"
 #include "HttpRequest.h"
diff -u -r -N squid-3.2.0.14/src/acl/Browser.cc squid-3.2.0.15/src/acl/Browser.cc
--- squid-3.2.0.14/src/acl/Browser.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/acl/Browser.cc	2012-02-06 04:52:31.000000000 +1300
@@ -34,7 +34,7 @@
  * Copyright (c) 2003, Robert Collins <robertc@squid-cache.org>
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "acl/Checklist.h"
 #include "acl/Browser.h"
 #include "acl/RegexData.h"
diff -u -r -N squid-3.2.0.14/src/acl/Certificate.cc squid-3.2.0.15/src/acl/Certificate.cc
--- squid-3.2.0.14/src/acl/Certificate.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/acl/Certificate.cc	2012-02-06 04:52:31.000000000 +1300
@@ -34,7 +34,7 @@
  * Copyright (c) 2003, Robert Collins <robertc@squid-cache.org>
  */
 
-#include "squid.h"
+#include "squid-old.h"
 
 /* MS Visual Studio Projects are monolithic, so we need the following
  * #if to exclude the SSL code from compile process when not needed.
diff -u -r -N squid-3.2.0.14/src/acl/CertificateData.cc squid-3.2.0.15/src/acl/CertificateData.cc
--- squid-3.2.0.14/src/acl/CertificateData.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/acl/CertificateData.cc	2012-02-06 04:52:31.000000000 +1300
@@ -34,7 +34,7 @@
  * Copyright (c) 2003, Robert Collins <robertc@squid-cache.org>
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "acl/CertificateData.h"
 #include "acl/Checklist.h"
 #include "wordlist.h"
diff -u -r -N squid-3.2.0.14/src/acl/Checklist.cc squid-3.2.0.15/src/acl/Checklist.cc
--- squid-3.2.0.14/src/acl/Checklist.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/acl/Checklist.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
  * Copyright (c) 2003, Robert Collins <robertc@squid-cache.org>
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "acl/Checklist.h"
 
 allow_t const &
diff -u -r -N squid-3.2.0.14/src/acl/DestinationDomain.cc squid-3.2.0.15/src/acl/DestinationDomain.cc
--- squid-3.2.0.14/src/acl/DestinationDomain.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/acl/DestinationDomain.cc	2012-02-06 04:52:31.000000000 +1300
@@ -34,7 +34,7 @@
  * Copyright (c) 2003, Robert Collins <robertc@squid-cache.org>
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "acl/DestinationDomain.h"
 #include "acl/Checklist.h"
 #include "acl/RegexData.h"
diff -u -r -N squid-3.2.0.14/src/acl/DestinationIp.cc squid-3.2.0.15/src/acl/DestinationIp.cc
--- squid-3.2.0.14/src/acl/DestinationIp.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/acl/DestinationIp.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
  * Copyright (c) 2003, Robert Collins <robertc@squid-cache.org>
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "acl/DestinationIp.h"
 #include "acl/FilledChecklist.h"
 #include "comm/Connection.h"
diff -u -r -N squid-3.2.0.14/src/acl/DomainData.cc squid-3.2.0.15/src/acl/DomainData.cc
--- squid-3.2.0.14/src/acl/DomainData.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/acl/DomainData.cc	2012-02-06 04:52:31.000000000 +1300
@@ -34,7 +34,7 @@
  * Copyright (c) 2003, Robert Collins <robertc@squid-cache.org>
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "acl/DomainData.h"
 #include "acl/Checklist.h"
 #include "wordlist.h"
diff -u -r -N squid-3.2.0.14/src/acl/Eui64.cc squid-3.2.0.15/src/acl/Eui64.cc
--- squid-3.2.0.14/src/acl/Eui64.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/acl/Eui64.cc	2012-02-06 04:52:31.000000000 +1300
@@ -32,7 +32,7 @@
  * Copyright (c) 2003, Robert Collins <robertc@squid-cache.org>
  */
 
-#include "squid.h"
+#include "squid-old.h"
 
 #if USE_SQUID_EUI
 
diff -u -r -N squid-3.2.0.14/src/acl/ExtUser.cc squid-3.2.0.15/src/acl/ExtUser.cc
--- squid-3.2.0.14/src/acl/ExtUser.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/acl/ExtUser.cc	2012-02-06 04:52:31.000000000 +1300
@@ -34,7 +34,7 @@
  * Copyright (c) 2003, Robert Collins <robertc@squid-cache.org>
  */
 
-#include "squid.h"
+#include "squid-old.h"
 
 #if USE_AUTH
 
diff -u -r -N squid-3.2.0.14/src/acl/FilledChecklist.cc squid-3.2.0.15/src/acl/FilledChecklist.cc
--- squid-3.2.0.14/src/acl/FilledChecklist.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/acl/FilledChecklist.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "squid.h"
+#include "squid-old.h"
 #include "HttpRequest.h"
 #include "HttpReply.h"
 #include "client_side.h"
@@ -24,8 +24,11 @@
     if (auth_user_request != NULL) {
         /* the filled_checklist lock */
         auth_user_request = NULL;
-        /* it might have been connection based */
-        if (conn()) {
+        // It might have been connection based
+        // In the case of sslBump we need to preserve authentication info
+        // XXX: need to re-evaluate this. ACL tests should not be playing with
+        // XXX: wider scoped TCP connection state, even if the helper lookup is stuck.
+        if (conn() && !conn()->switchedToHttps()) {
             conn()->auth_user_request = NULL;
         }
     }
diff -u -r -N squid-3.2.0.14/src/acl/FilledChecklist.h squid-3.2.0.15/src/acl/FilledChecklist.h
--- squid-3.2.0.14/src/acl/FilledChecklist.h	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/acl/FilledChecklist.h	2012-02-06 04:52:31.000000000 +1300
@@ -56,7 +56,7 @@
 
     char rfc931[USER_IDENT_SZ];
 #if USE_AUTH
-    AuthUserRequest::Pointer auth_user_request;
+    Auth::UserRequest::Pointer auth_user_request;
 #endif
 #if SQUID_SNMP
     char *snmp_community;
diff -u -r -N squid-3.2.0.14/src/acl/Gadgets.cc squid-3.2.0.15/src/acl/Gadgets.cc
--- squid-3.2.0.14/src/acl/Gadgets.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/acl/Gadgets.cc	2012-02-06 04:52:31.000000000 +1300
@@ -38,7 +38,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "acl/Acl.h"
 #include "acl/Checklist.h"
 #include "acl/Strategised.h"
diff -u -r -N squid-3.2.0.14/src/acl/HierCode.cc squid-3.2.0.15/src/acl/HierCode.cc
--- squid-3.2.0.14/src/acl/HierCode.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/acl/HierCode.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "squid.h"
+#include "squid-old.h"
 #include "acl/HierCode.h"
 #include "acl/HierCodeData.h"
 #include "acl/Checklist.h"
diff -u -r -N squid-3.2.0.14/src/acl/HierCodeData.cc squid-3.2.0.15/src/acl/HierCodeData.cc
--- squid-3.2.0.14/src/acl/HierCodeData.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/acl/HierCodeData.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "squid.h"
+#include "squid-old.h"
 #include "acl/HierCodeData.h"
 #include "acl/Checklist.h"
 #include "hier_code.h"
diff -u -r -N squid-3.2.0.14/src/acl/HttpHeaderData.cc squid-3.2.0.15/src/acl/HttpHeaderData.cc
--- squid-3.2.0.14/src/acl/HttpHeaderData.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/acl/HttpHeaderData.cc	2012-02-06 04:52:31.000000000 +1300
@@ -34,7 +34,7 @@
  * Copyright (c) 2003, Robert Collins <robertc@squid-cache.org>
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "acl/HttpHeaderData.h"
 #include "acl/Checklist.h"
 #include "acl/Acl.h"
diff -u -r -N squid-3.2.0.14/src/acl/HttpRepHeader.cc squid-3.2.0.15/src/acl/HttpRepHeader.cc
--- squid-3.2.0.14/src/acl/HttpRepHeader.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/acl/HttpRepHeader.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
  * Copyright (c) 2003, Robert Collins <robertc@squid-cache.org>
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "acl/HttpRepHeader.h"
 #include "acl/HttpHeaderData.h"
 #include "acl/Checklist.h"
diff -u -r -N squid-3.2.0.14/src/acl/HttpReqHeader.cc squid-3.2.0.15/src/acl/HttpReqHeader.cc
--- squid-3.2.0.14/src/acl/HttpReqHeader.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/acl/HttpReqHeader.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
  * Copyright (c) 2003, Robert Collins <robertc@squid-cache.org>
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "acl/HttpReqHeader.h"
 #include "acl/HttpHeaderData.h"
 #include "acl/Checklist.h"
diff -u -r -N squid-3.2.0.14/src/acl/HttpStatus.cc squid-3.2.0.15/src/acl/HttpStatus.cc
--- squid-3.2.0.14/src/acl/HttpStatus.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/acl/HttpStatus.cc	2012-02-06 04:52:31.000000000 +1300
@@ -34,11 +34,11 @@
  * Copyright (c) 2003, Robert Collins <robertc@squid-cache.org>
  */
 
-#include "config.h"
+#include "squid.h"
 #if _SQUID_CYGWIN_
 #include <squid_windows.h>
 #endif
-#include "squid.h"
+#include "squid-old.h"
 
 #include "acl/HttpStatus.h"
 #include "acl/FilledChecklist.h"
diff -u -r -N squid-3.2.0.14/src/acl/IntRange.cc squid-3.2.0.15/src/acl/IntRange.cc
--- squid-3.2.0.14/src/acl/IntRange.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/acl/IntRange.cc	2012-02-06 04:52:31.000000000 +1300
@@ -34,7 +34,7 @@
  * Copyright (c) 2003, Robert Collins <robertc@squid-cache.org>
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "acl/IntRange.h"
 #include "wordlist.h"
 #include "Parsing.h"
diff -u -r -N squid-3.2.0.14/src/acl/Ip.cc squid-3.2.0.15/src/acl/Ip.cc
--- squid-3.2.0.14/src/acl/Ip.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/acl/Ip.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
  * Copyright (c) 2003, Robert Collins <robertc@squid-cache.org>
  */
 
-#include "squid.h"
+#include "squid-old.h"
 //#include "compat/getaddrinfo.h"
 #include "acl/Ip.h"
 #include "acl/Checklist.h"
diff -u -r -N squid-3.2.0.14/src/acl/MaxConnection.cc squid-3.2.0.15/src/acl/MaxConnection.cc
--- squid-3.2.0.14/src/acl/MaxConnection.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/acl/MaxConnection.cc	2012-02-06 04:52:31.000000000 +1300
@@ -34,7 +34,7 @@
  * Copyright (c) 2003, Robert Collins <robertc@squid-cache.org>
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "acl/FilledChecklist.h"
 #include "acl/MaxConnection.h"
 #include "wordlist.h"
diff -u -r -N squid-3.2.0.14/src/acl/Method.cc squid-3.2.0.15/src/acl/Method.cc
--- squid-3.2.0.14/src/acl/Method.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/acl/Method.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
  * Copyright (c) 2003, Robert Collins <robertc@squid-cache.org>
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "acl/Method.h"
 #include "acl/MethodData.h"
 #include "acl/Checklist.h"
diff -u -r -N squid-3.2.0.14/src/acl/MethodData.cc squid-3.2.0.15/src/acl/MethodData.cc
--- squid-3.2.0.14/src/acl/MethodData.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/acl/MethodData.cc	2012-02-06 04:52:31.000000000 +1300
@@ -34,7 +34,7 @@
  * Copyright (c) 2003, Robert Collins <robertc@squid-cache.org>
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "acl/MethodData.h"
 #include "acl/Checklist.h"
 #include "HttpRequestMethod.h"
diff -u -r -N squid-3.2.0.14/src/acl/MyIp.cc squid-3.2.0.15/src/acl/MyIp.cc
--- squid-3.2.0.14/src/acl/MyIp.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/acl/MyIp.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,9 +33,9 @@
  * Copyright (c) 2003, Robert Collins <robertc@squid-cache.org>
  */
 
-#include "squid.h"
-#include "acl/MyIp.h"
+#include "squid-old.h"
 #include "acl/FilledChecklist.h"
+#include "acl/MyIp.h"
 
 char const *
 ACLMyIP::typeString() const
diff -u -r -N squid-3.2.0.14/src/acl/MyPort.cc squid-3.2.0.15/src/acl/MyPort.cc
--- squid-3.2.0.14/src/acl/MyPort.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/acl/MyPort.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,10 +33,10 @@
  * Copyright (c) 2003, Robert Collins <robertc@squid-cache.org>
  */
 
-#include "squid.h"
-#include "acl/MyPort.h"
+#include "squid-old.h"
 #include "acl/IntRange.h"
 #include "acl/Checklist.h"
+#include "acl/MyPort.h"
 
 int
 ACLMyPortStrategy::match (ACLData<MatchType> * &data, ACLFilledChecklist *checklist)
diff -u -r -N squid-3.2.0.14/src/acl/MyPortName.cc squid-3.2.0.15/src/acl/MyPortName.cc
--- squid-3.2.0.14/src/acl/MyPortName.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/acl/MyPortName.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
  * Copyright (c) 2003, Robert Collins <robertc@squid-cache.org>
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "ProtoPort.h"
 #include "acl/MyPortName.h"
 #include "acl/StringData.h"
diff -u -r -N squid-3.2.0.14/src/acl/PeerName.cc squid-3.2.0.15/src/acl/PeerName.cc
--- squid-3.2.0.14/src/acl/PeerName.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/acl/PeerName.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "squid.h"
+#include "squid-old.h"
 #include "acl/PeerName.h"
 #include "acl/StringData.h"
 #include "acl/Checklist.h"
diff -u -r -N squid-3.2.0.14/src/acl/Protocol.cc squid-3.2.0.15/src/acl/Protocol.cc
--- squid-3.2.0.14/src/acl/Protocol.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/acl/Protocol.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
  * Copyright (c) 2003, Robert Collins <robertc@squid-cache.org>
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "acl/Protocol.h"
 #include "acl/ProtocolData.h"
 #include "acl/Checklist.h"
diff -u -r -N squid-3.2.0.14/src/acl/ProtocolData.cc squid-3.2.0.15/src/acl/ProtocolData.cc
--- squid-3.2.0.14/src/acl/ProtocolData.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/acl/ProtocolData.cc	2012-02-06 04:52:31.000000000 +1300
@@ -34,7 +34,7 @@
  * Copyright (c) 2003, Robert Collins <robertc@squid-cache.org>
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "acl/ProtocolData.h"
 #include "acl/Checklist.h"
 #include "URLScheme.h"
diff -u -r -N squid-3.2.0.14/src/acl/Random.cc squid-3.2.0.15/src/acl/Random.cc
--- squid-3.2.0.14/src/acl/Random.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/acl/Random.cc	2012-02-06 04:52:31.000000000 +1300
@@ -32,7 +32,7 @@
  * Copyright (c) 2003, Robert Collins <robertc@squid-cache.org>
  */
 
-#include "squid.h"
+#include "squid-old.h"
 
 #include "acl/FilledChecklist.h"
 #include "acl/Random.h"
diff -u -r -N squid-3.2.0.14/src/acl/Referer.cc squid-3.2.0.15/src/acl/Referer.cc
--- squid-3.2.0.14/src/acl/Referer.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/acl/Referer.cc	2012-02-06 04:52:31.000000000 +1300
@@ -34,7 +34,7 @@
  * Copyright (c) 2003, Robert Collins <robertc@squid-cache.org>
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "acl/Referer.h"
 #include "acl/Checklist.h"
 #include "acl/RegexData.h"
diff -u -r -N squid-3.2.0.14/src/acl/RegexData.cc squid-3.2.0.15/src/acl/RegexData.cc
--- squid-3.2.0.14/src/acl/RegexData.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/acl/RegexData.cc	2012-02-06 04:52:31.000000000 +1300
@@ -36,7 +36,7 @@
  * Copyright (c) 2011, Marcus Kool
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "acl/RegexData.h"
 #include "acl/Checklist.h"
 #include "acl/Acl.h"
diff -u -r -N squid-3.2.0.14/src/acl/ReplyMimeType.cc squid-3.2.0.15/src/acl/ReplyMimeType.cc
--- squid-3.2.0.14/src/acl/ReplyMimeType.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/acl/ReplyMimeType.cc	2012-02-06 04:52:31.000000000 +1300
@@ -34,7 +34,7 @@
  * Copyright (c) 2003, Robert Collins <robertc@squid-cache.org>
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "acl/ReplyMimeType.h"
 #include "acl/Checklist.h"
 #include "acl/RegexData.h"
diff -u -r -N squid-3.2.0.14/src/acl/RequestMimeType.cc squid-3.2.0.15/src/acl/RequestMimeType.cc
--- squid-3.2.0.14/src/acl/RequestMimeType.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/acl/RequestMimeType.cc	2012-02-06 04:52:31.000000000 +1300
@@ -34,7 +34,7 @@
  * Copyright (c) 2003, Robert Collins <robertc@squid-cache.org>
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "acl/RequestMimeType.h"
 #include "acl/Checklist.h"
 #include "acl/RegexData.h"
diff -u -r -N squid-3.2.0.14/src/acl/SourceDomain.cc squid-3.2.0.15/src/acl/SourceDomain.cc
--- squid-3.2.0.14/src/acl/SourceDomain.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/acl/SourceDomain.cc	2012-02-06 04:52:31.000000000 +1300
@@ -34,7 +34,7 @@
  * Copyright (c) 2003, Robert Collins <robertc@squid-cache.org>
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "acl/SourceDomain.h"
 #include "acl/Checklist.h"
 #include "acl/RegexData.h"
diff -u -r -N squid-3.2.0.14/src/acl/SourceIp.cc squid-3.2.0.15/src/acl/SourceIp.cc
--- squid-3.2.0.14/src/acl/SourceIp.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/acl/SourceIp.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
  * Copyright (c) 2003, Robert Collins <robertc@squid-cache.org>
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "acl/SourceIp.h"
 #include "acl/FilledChecklist.h"
 
diff -u -r -N squid-3.2.0.14/src/acl/SslError.cc squid-3.2.0.15/src/acl/SslError.cc
--- squid-3.2.0.14/src/acl/SslError.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/acl/SslError.cc	2012-02-06 04:52:31.000000000 +1300
@@ -3,7 +3,7 @@
  * $Id$
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "acl/SslError.h"
 #include "acl/SslErrorData.h"
 #include "acl/Checklist.h"
diff -u -r -N squid-3.2.0.14/src/acl/SslErrorData.cc squid-3.2.0.15/src/acl/SslErrorData.cc
--- squid-3.2.0.14/src/acl/SslErrorData.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/acl/SslErrorData.cc	2012-02-06 04:52:31.000000000 +1300
@@ -2,7 +2,7 @@
  * $Id$
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "acl/SslErrorData.h"
 #include "acl/Checklist.h"
 #include "wordlist.h"
diff -u -r -N squid-3.2.0.14/src/acl/Strategised.cc squid-3.2.0.15/src/acl/Strategised.cc
--- squid-3.2.0.14/src/acl/Strategised.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/acl/Strategised.cc	2012-02-06 04:52:31.000000000 +1300
@@ -34,7 +34,7 @@
  * Copyright (c) 2003, Robert Collins <robertc@squid-cache.org>
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "acl/Strategised.h"
 
 /*
diff -u -r -N squid-3.2.0.14/src/acl/StringData.cc squid-3.2.0.15/src/acl/StringData.cc
--- squid-3.2.0.14/src/acl/StringData.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/acl/StringData.cc	2012-02-06 04:52:31.000000000 +1300
@@ -34,7 +34,7 @@
  * Copyright (c) 2003, Robert Collins <robertc@squid-cache.org>
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "acl/StringData.h"
 #include "acl/Checklist.h"
 #include "wordlist.h"
diff -u -r -N squid-3.2.0.14/src/acl/Tag.cc squid-3.2.0.15/src/acl/Tag.cc
--- squid-3.2.0.14/src/acl/Tag.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/acl/Tag.cc	2012-02-06 04:52:31.000000000 +1300
@@ -34,7 +34,7 @@
  * Copyright (c) 2009, Henrik Nordstrom <henrik@henriknordstrom.net>
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "acl/Tag.h"
 #include "acl/StringData.h"
 #include "acl/Checklist.h"
diff -u -r -N squid-3.2.0.14/src/acl/Time.cc squid-3.2.0.15/src/acl/Time.cc
--- squid-3.2.0.14/src/acl/Time.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/acl/Time.cc	2012-02-06 04:52:31.000000000 +1300
@@ -34,7 +34,7 @@
  * Copyright (c) 2003, Robert Collins <robertc@squid-cache.org>
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "acl/Time.h"
 #include "acl/TimeData.h"
 #include "SquidTime.h"
diff -u -r -N squid-3.2.0.14/src/acl/TimeData.cc squid-3.2.0.15/src/acl/TimeData.cc
--- squid-3.2.0.14/src/acl/TimeData.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/acl/TimeData.cc	2012-02-06 04:52:31.000000000 +1300
@@ -34,7 +34,7 @@
  * Copyright (c) 2003, Robert Collins <robertc@squid-cache.org>
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "acl/TimeData.h"
 #include "acl/Checklist.h"
 #include "wordlist.h"
diff -u -r -N squid-3.2.0.14/src/acl/Url.cc squid-3.2.0.15/src/acl/Url.cc
--- squid-3.2.0.14/src/acl/Url.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/acl/Url.cc	2012-02-06 04:52:31.000000000 +1300
@@ -34,7 +34,7 @@
  * Copyright (c) 2003, Robert Collins <robertc@squid-cache.org>
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "acl/Url.h"
 #include "acl/Checklist.h"
 #include "acl/RegexData.h"
diff -u -r -N squid-3.2.0.14/src/acl/UrlPath.cc squid-3.2.0.15/src/acl/UrlPath.cc
--- squid-3.2.0.14/src/acl/UrlPath.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/acl/UrlPath.cc	2012-02-06 04:52:31.000000000 +1300
@@ -34,7 +34,7 @@
  * Copyright (c) 2003, Robert Collins <robertc@squid-cache.org>
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "acl/UrlPath.h"
 #include "acl/Checklist.h"
 #include "acl/RegexData.h"
diff -u -r -N squid-3.2.0.14/src/acl/UrlPort.cc squid-3.2.0.15/src/acl/UrlPort.cc
--- squid-3.2.0.14/src/acl/UrlPort.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/acl/UrlPort.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
  * Copyright (c) 2003, Robert Collins <robertc@squid-cache.org>
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "acl/UrlPort.h"
 #include "acl/IntRange.h"
 #include "acl/Checklist.h"
diff -u -r -N squid-3.2.0.14/src/acl/UserData.cc squid-3.2.0.15/src/acl/UserData.cc
--- squid-3.2.0.14/src/acl/UserData.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/acl/UserData.cc	2012-02-06 04:52:31.000000000 +1300
@@ -34,7 +34,7 @@
  * Copyright (c) 2003, Robert Collins <robertc@squid-cache.org>
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "acl/UserData.h"
 #include "acl/Checklist.h"
 #include "wordlist.h"
diff -u -r -N squid-3.2.0.14/src/AclRegs.cc squid-3.2.0.15/src/AclRegs.cc
--- squid-3.2.0.14/src/AclRegs.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/AclRegs.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "squid.h"
+#include "squid-old.h"
 
 /** This file exists to provide satic registration code to executables
     that need ACLs. We cannot place this code in acl/lib*.la because it
diff -u -r -N squid-3.2.0.14/src/adaptation/AccessCheck.cc squid-3.2.0.15/src/adaptation/AccessCheck.cc
--- squid-3.2.0.14/src/adaptation/AccessCheck.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/adaptation/AccessCheck.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "squid.h"
+#include "squid-old.h"
 #include "structs.h"
 
 #include "ConfigParser.h"
diff -u -r -N squid-3.2.0.14/src/adaptation/AccessRule.cc squid-3.2.0.15/src/adaptation/AccessRule.cc
--- squid-3.2.0.14/src/adaptation/AccessRule.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/adaptation/AccessRule.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "squid.h"
+#include "squid-old.h"
 #include "structs.h"
 
 #include "ConfigParser.h"
diff -u -r -N squid-3.2.0.14/src/adaptation/Answer.cc squid-3.2.0.15/src/adaptation/Answer.cc
--- squid-3.2.0.14/src/adaptation/Answer.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/adaptation/Answer.cc	2012-02-06 04:52:31.000000000 +1300
@@ -2,7 +2,7 @@
  * DEBUG: section 93    ICAP (RFC 3507) Client
  */
 
-#include "config.h"
+#include "squid.h"
 #include "adaptation/Answer.h"
 #include "base/AsyncJobCalls.h"
 
diff -u -r -N squid-3.2.0.14/src/adaptation/Config.cc squid-3.2.0.15/src/adaptation/Config.cc
--- squid-3.2.0.14/src/adaptation/Config.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/adaptation/Config.cc	2012-02-06 04:52:31.000000000 +1300
@@ -30,7 +30,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "structs.h"
 
 #include "ConfigParser.h"
diff -u -r -N squid-3.2.0.14/src/adaptation/DynamicGroupCfg.cc squid-3.2.0.15/src/adaptation/DynamicGroupCfg.cc
--- squid-3.2.0.14/src/adaptation/DynamicGroupCfg.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/adaptation/DynamicGroupCfg.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "config.h"
+#include "squid.h"
 
 #include "adaptation/DynamicGroupCfg.h"
 
diff -u -r -N squid-3.2.0.14/src/adaptation/ecap/Config.cc squid-3.2.0.15/src/adaptation/ecap/Config.cc
--- squid-3.2.0.14/src/adaptation/ecap/Config.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/adaptation/ecap/Config.cc	2012-02-06 04:52:31.000000000 +1300
@@ -2,7 +2,7 @@
  * $Id$
  * DEBUG: section 93    eCAP Interface
  */
-#include "squid.h"
+#include "squid-old.h"
 
 #include "adaptation/ecap/Host.h"
 #include "adaptation/ecap/ServiceRep.h"
diff -u -r -N squid-3.2.0.14/src/adaptation/ecap/Host.cc squid-3.2.0.15/src/adaptation/ecap/Host.cc
--- squid-3.2.0.14/src/adaptation/ecap/Host.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/adaptation/ecap/Host.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,7 +1,7 @@
 /*
  * DEBUG: section 93    eCAP Interface
  */
-#include "squid.h"
+#include "squid-old.h"
 #include <libecap/adapter/service.h>
 #include <libecap/common/names.h>
 #include <libecap/common/registry.h>
diff -u -r -N squid-3.2.0.14/src/adaptation/ecap/MessageRep.cc squid-3.2.0.15/src/adaptation/ecap/MessageRep.cc
--- squid-3.2.0.14/src/adaptation/ecap/MessageRep.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/adaptation/ecap/MessageRep.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,7 +1,7 @@
 /*
  * DEBUG: section 93    eCAP Interface
  */
-#include "squid.h"
+#include "squid-old.h"
 #include "HttpRequest.h"
 #include "HttpReply.h"
 #include "BodyPipe.h"
diff -u -r -N squid-3.2.0.14/src/adaptation/ecap/ServiceRep.cc squid-3.2.0.15/src/adaptation/ecap/ServiceRep.cc
--- squid-3.2.0.14/src/adaptation/ecap/ServiceRep.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/adaptation/ecap/ServiceRep.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,7 +1,7 @@
 /*
  * DEBUG: section 93    eCAP Interface
  */
-#include "squid.h"
+#include "squid-old.h"
 #include <list>
 #include <libecap/adapter/service.h>
 #include <libecap/common/options.h>
diff -u -r -N squid-3.2.0.14/src/adaptation/ecap/XactionRep.cc squid-3.2.0.15/src/adaptation/ecap/XactionRep.cc
--- squid-3.2.0.14/src/adaptation/ecap/XactionRep.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/adaptation/ecap/XactionRep.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,7 +1,7 @@
 /*
  * DEBUG: section 93    eCAP Interface
  */
-#include "squid.h"
+#include "squid-old.h"
 #include <libecap/common/area.h>
 #include <libecap/common/delay.h>
 #include <libecap/common/named_values.h>
diff -u -r -N squid-3.2.0.14/src/adaptation/Elements.cc squid-3.2.0.15/src/adaptation/Elements.cc
--- squid-3.2.0.14/src/adaptation/Elements.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/adaptation/Elements.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "squid.h"
+#include "squid-old.h"
 #include "adaptation/Elements.h"
 
 const char *Adaptation::crlf = "\r\n";
diff -u -r -N squid-3.2.0.14/src/adaptation/History.cc squid-3.2.0.15/src/adaptation/History.cc
--- squid-3.2.0.14/src/adaptation/History.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/adaptation/History.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "config.h"
+#include "squid.h"
 #include "adaptation/Config.h"
 #include "adaptation/History.h"
 #include "base/TextException.h"
diff -u -r -N squid-3.2.0.14/src/adaptation/icap/Client.cc squid-3.2.0.15/src/adaptation/icap/Client.cc
--- squid-3.2.0.14/src/adaptation/icap/Client.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/adaptation/icap/Client.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "squid.h"
+#include "squid-old.h"
 #include "adaptation/icap/Client.h"
 
 void Adaptation::Icap::InitModule()
diff -u -r -N squid-3.2.0.14/src/adaptation/icap/Config.cc squid-3.2.0.15/src/adaptation/icap/Config.cc
--- squid-3.2.0.14/src/adaptation/icap/Config.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/adaptation/icap/Config.cc	2012-02-06 04:52:31.000000000 +1300
@@ -32,7 +32,7 @@
  * Copyright (c) 2003, Robert Collins <robertc@squid-cache.org>
  */
 
-#include "squid.h"
+#include "squid-old.h"
 
 #include "ConfigParser.h"
 #include "Store.h"
diff -u -r -N squid-3.2.0.14/src/adaptation/icap/Elements.cc squid-3.2.0.15/src/adaptation/icap/Elements.cc
--- squid-3.2.0.14/src/adaptation/icap/Elements.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/adaptation/icap/Elements.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "squid.h"
+#include "squid-old.h"
 #include "adaptation/icap/Elements.h"
 
 // TODO: remove this file?
diff -u -r -N squid-3.2.0.14/src/adaptation/icap/History.cc squid-3.2.0.15/src/adaptation/icap/History.cc
--- squid-3.2.0.14/src/adaptation/icap/History.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/adaptation/icap/History.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "squid.h"
+#include "squid-old.h"
 #include "adaptation/icap/History.h"
 #include "globals.h"
 #include "SquidTime.h"
diff -u -r -N squid-3.2.0.14/src/adaptation/icap/icap_log.cc squid-3.2.0.15/src/adaptation/icap/icap_log.cc
--- squid-3.2.0.14/src/adaptation/icap/icap_log.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/adaptation/icap/icap_log.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "squid.h"
+#include "squid-old.h"
 #include "icap_log.h"
 #include "AccessLogEntry.h"
 #include "log/File.h"
diff -u -r -N squid-3.2.0.14/src/adaptation/icap/Launcher.cc squid-3.2.0.15/src/adaptation/icap/Launcher.cc
--- squid-3.2.0.14/src/adaptation/icap/Launcher.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/adaptation/icap/Launcher.cc	2012-02-06 04:52:31.000000000 +1300
@@ -2,7 +2,7 @@
  * DEBUG: section 93    ICAP (RFC 3507) Client
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "acl/FilledChecklist.h"
 #include "adaptation/Answer.h"
 #include "adaptation/icap/Launcher.h"
diff -u -r -N squid-3.2.0.14/src/adaptation/icap/ModXact.cc squid-3.2.0.15/src/adaptation/icap/ModXact.cc
--- squid-3.2.0.14/src/adaptation/icap/ModXact.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/adaptation/icap/ModXact.cc	2012-02-06 04:52:31.000000000 +1300
@@ -2,7 +2,7 @@
  * DEBUG: section 93    ICAP (RFC 3507) Client
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "AccessLogEntry.h"
 #include "adaptation/Answer.h"
 #include "adaptation/History.h"
@@ -945,10 +945,8 @@
     Must(!adapted.header);
     {
         HttpMsg::Pointer newHead;
-        if (const HttpRequest *oldR = dynamic_cast<const HttpRequest*>(oldHead)) {
+        if (dynamic_cast<const HttpRequest*>(oldHead)) {
             HttpRequest::Pointer newR(new HttpRequest);
-            newR->canonical = oldR->canonical ?
-                              xstrdup(oldR->canonical) : NULL; // parse() does not set it
             newHead = newR;
         } else if (dynamic_cast<const HttpReply*>(oldHead)) {
             newHead = new HttpReply;
@@ -965,6 +963,9 @@
 
     Must(adapted.header->parse(&httpBuf, true, &error));
 
+    if (HttpRequest *r = dynamic_cast<HttpRequest*>(adapted.header))
+        urlCanonical(r); // parse does not set HttpRequest::canonical
+
     Must(adapted.header->hdr_sz == httpBuf.contentSize()); // no leftovers
 
     httpBuf.clean();
diff -u -r -N squid-3.2.0.14/src/adaptation/icap/Options.cc squid-3.2.0.15/src/adaptation/icap/Options.cc
--- squid-3.2.0.14/src/adaptation/icap/Options.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/adaptation/icap/Options.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "squid.h"
+#include "squid-old.h"
 #include "adaptation/icap/Config.h"
 #include "adaptation/icap/Options.h"
 #include "base/TextException.h"
diff -u -r -N squid-3.2.0.14/src/adaptation/icap/Options.h squid-3.2.0.15/src/adaptation/icap/Options.h
--- squid-3.2.0.14/src/adaptation/icap/Options.h	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/adaptation/icap/Options.h	2012-02-06 04:52:31.000000000 +1300
@@ -34,7 +34,7 @@
 #ifndef SQUID_ICAPOPTIONS_H
 #define SQUID_ICAPOPTIONS_H
 
-#include "squid.h"
+#include "squid-old.h"
 #include "adaptation/icap/ServiceRep.h"
 
 class wordlist;
diff -u -r -N squid-3.2.0.14/src/adaptation/icap/OptXact.cc squid-3.2.0.15/src/adaptation/icap/OptXact.cc
--- squid-3.2.0.14/src/adaptation/icap/OptXact.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/adaptation/icap/OptXact.cc	2012-02-06 04:52:31.000000000 +1300
@@ -2,7 +2,7 @@
  * DEBUG: section 93    ICAP (RFC 3507) Client
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "comm.h"
 #include "HttpReply.h"
 
diff -u -r -N squid-3.2.0.14/src/adaptation/icap/ServiceRep.cc squid-3.2.0.15/src/adaptation/icap/ServiceRep.cc
--- squid-3.2.0.14/src/adaptation/icap/ServiceRep.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/adaptation/icap/ServiceRep.cc	2012-02-06 04:52:31.000000000 +1300
@@ -2,7 +2,7 @@
  * DEBUG: section 93    ICAP (RFC 3507) Client
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "adaptation/Answer.h"
 #include "adaptation/icap/Config.h"
 #include "adaptation/icap/ModXact.h"
diff -u -r -N squid-3.2.0.14/src/adaptation/icap/Xaction.cc squid-3.2.0.15/src/adaptation/icap/Xaction.cc
--- squid-3.2.0.14/src/adaptation/icap/Xaction.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/adaptation/icap/Xaction.cc	2012-02-06 04:52:31.000000000 +1300
@@ -2,7 +2,7 @@
  * DEBUG: section 93    ICAP (RFC 3507) Client
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "comm.h"
 #include "comm/Connection.h"
 #include "comm/ConnOpener.h"
@@ -234,8 +234,7 @@
     typedef CommCbMemFunT<Adaptation::Icap::Xaction, CommTimeoutCbParams> TimeoutDialer;
     AsyncCall::Pointer timeoutCall =  asyncCall(93, 5, "Adaptation::Icap::Xaction::noteCommTimedout",
                                       TimeoutDialer(this,&Adaptation::Icap::Xaction::noteCommTimedout));
-    commSetTimeout(io.conn->fd, TheConfig.connect_timeout(
-                       service().cfg().bypass), timeoutCall);
+    commSetConnTimeout(io.conn, TheConfig.connect_timeout(service().cfg().bypass), timeoutCall);
 
     typedef CommCbMemFunT<Adaptation::Icap::Xaction, CommCloseCbParams> CloseDialer;
     closer =  asyncCall(93, 5, "Adaptation::Icap::Xaction::noteCommClosed",
diff -u -r -N squid-3.2.0.14/src/adaptation/Initiate.cc squid-3.2.0.15/src/adaptation/Initiate.cc
--- squid-3.2.0.14/src/adaptation/Initiate.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/adaptation/Initiate.cc	2012-02-06 04:52:31.000000000 +1300
@@ -2,7 +2,7 @@
  * DEBUG: section 93    ICAP (RFC 3507) Client
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "HttpMsg.h"
 #include "adaptation/Answer.h"
 #include "adaptation/Initiator.h"
diff -u -r -N squid-3.2.0.14/src/adaptation/Initiator.cc squid-3.2.0.15/src/adaptation/Initiator.cc
--- squid-3.2.0.14/src/adaptation/Initiator.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/adaptation/Initiator.cc	2012-02-06 04:52:31.000000000 +1300
@@ -2,7 +2,7 @@
  * DEBUG: section 93    ICAP (RFC 3507) Client
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "adaptation/Initiate.h"
 #include "adaptation/Initiator.h"
 #include "base/AsyncJobCalls.h"
diff -u -r -N squid-3.2.0.14/src/adaptation/Iterator.cc squid-3.2.0.15/src/adaptation/Iterator.cc
--- squid-3.2.0.14/src/adaptation/Iterator.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/adaptation/Iterator.cc	2012-02-06 04:52:31.000000000 +1300
@@ -2,7 +2,7 @@
  * DEBUG: section 93    Adaptation
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "adaptation/Answer.h"
 #include "adaptation/Config.h"
 #include "adaptation/Iterator.h"
diff -u -r -N squid-3.2.0.14/src/adaptation/Message.cc squid-3.2.0.15/src/adaptation/Message.cc
--- squid-3.2.0.14/src/adaptation/Message.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/adaptation/Message.cc	2012-02-06 04:52:31.000000000 +1300
@@ -2,7 +2,7 @@
  * DEBUG: section 93    Adaptation
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "adaptation/Message.h"
 #include "base/TextException.h"
 #include "HttpMsg.h"
diff -u -r -N squid-3.2.0.14/src/adaptation/Service.cc squid-3.2.0.15/src/adaptation/Service.cc
--- squid-3.2.0.14/src/adaptation/Service.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/adaptation/Service.cc	2012-02-06 04:52:31.000000000 +1300
@@ -2,7 +2,7 @@
  * DEBUG: section 93    Adaptation
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "HttpRequest.h"
 #include "adaptation/ServiceFilter.h"
 #include "adaptation/Service.h"
diff -u -r -N squid-3.2.0.14/src/adaptation/ServiceConfig.cc squid-3.2.0.15/src/adaptation/ServiceConfig.cc
--- squid-3.2.0.14/src/adaptation/ServiceConfig.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/adaptation/ServiceConfig.cc	2012-02-06 04:52:31.000000000 +1300
@@ -2,7 +2,7 @@
  * DEBUG: section 93    Adaptation
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "ConfigParser.h"
 #include "adaptation/ServiceConfig.h"
 #include "ip/tools.h"
diff -u -r -N squid-3.2.0.14/src/adaptation/ServiceFilter.cc squid-3.2.0.15/src/adaptation/ServiceFilter.cc
--- squid-3.2.0.14/src/adaptation/ServiceFilter.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/adaptation/ServiceFilter.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "squid.h"
+#include "squid-old.h"
 #include "HttpRequest.h"
 #include "HttpReply.h"
 #include "adaptation/ServiceFilter.h"
diff -u -r -N squid-3.2.0.14/src/adaptation/ServiceGroups.cc squid-3.2.0.15/src/adaptation/ServiceGroups.cc
--- squid-3.2.0.14/src/adaptation/ServiceGroups.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/adaptation/ServiceGroups.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "squid.h"
+#include "squid-old.h"
 
 #include "ConfigParser.h"
 #include "adaptation/Config.h"
diff -u -r -N squid-3.2.0.14/src/anyp/ProtocolType.cc squid-3.2.0.15/src/anyp/ProtocolType.cc
--- squid-3.2.0.14/src/anyp/ProtocolType.cc	2011-12-13 01:29:22.000000000 +1300
+++ squid-3.2.0.15/src/anyp/ProtocolType.cc	2012-02-06 06:02:41.000000000 +1300
@@ -1,7 +1,7 @@
 /*
  * Auto-Generated File. Changes will be destroyed.
  */
-#include "config.h"
+#include "squid.h"
 #include "anyp/ProtocolType.h"
 namespace AnyP
 {
diff -u -r -N squid-3.2.0.14/src/AsyncEngine.cc squid-3.2.0.15/src/AsyncEngine.cc
--- squid-3.2.0.14/src/AsyncEngine.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/AsyncEngine.cc	2012-02-06 04:52:31.000000000 +1300
@@ -31,5 +31,5 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 #include "AsyncEngine.h"
diff -u -r -N squid-3.2.0.14/src/AsyncEngine.h squid-3.2.0.15/src/AsyncEngine.h
--- squid-3.2.0.14/src/AsyncEngine.h	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/AsyncEngine.h	2012-02-06 04:52:31.000000000 +1300
@@ -34,7 +34,7 @@
 #ifndef SQUID_ASYNCENGINE_H
 #define SQUID_ASYNCENGINE_H
 
-#include "squid.h"
+#include "squid-old.h"
 
 
 /* Abstract interface for async engines which an event loop can utilise.
diff -u -r -N squid-3.2.0.14/src/auth/Acl.cc squid-3.2.0.15/src/auth/Acl.cc
--- squid-3.2.0.14/src/auth/Acl.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/auth/Acl.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "squid.h"
+#include "squid-old.h"
 #include "acl/Acl.h"
 #include "acl/FilledChecklist.h"
 #include "auth/UserRequest.h"
@@ -19,6 +19,13 @@
     if (NULL == request) {
         fatal ("requiresRequest SHOULD have been true for this ACL!!");
         return 0;
+    } else if (request->flags.sslBumped) {
+        debugs(28, 5, "SslBumped request: It is an encapsulated request do not authenticate");
+        checklist->auth_user_request = checklist->conn() != NULL ? checklist->conn()->auth_user_request : request->auth_user_request;
+        if (checklist->auth_user_request != NULL)
+            return 1;
+        else
+            return 0;
     } else if (request->flags.accelerated) {
         /* WWW authorization on accelerated requests */
         headertype = HDR_AUTHORIZATION;
@@ -32,7 +39,7 @@
 
     /* get authed here */
     /* Note: this fills in auth_user_request when applicable */
-    const AuthAclState result = AuthUserRequest::tryToAuthenticateAndSetAuthUser(
+    const AuthAclState result = Auth::UserRequest::tryToAuthenticateAndSetAuthUser(
                                     &checklist->auth_user_request, headertype, request,
                                     checklist->conn(), checklist->src_addr);
     switch (result) {
diff -u -r -N squid-3.2.0.14/src/auth/AclMaxUserIp.cc squid-3.2.0.15/src/auth/AclMaxUserIp.cc
--- squid-3.2.0.14/src/auth/AclMaxUserIp.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/auth/AclMaxUserIp.cc	2012-02-06 04:52:31.000000000 +1300
@@ -34,7 +34,7 @@
  * Copyright (c) 2003, Robert Collins <robertc@squid-cache.org>
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "acl/FilledChecklist.h"
 #include "auth/Acl.h"
 #include "auth/AclMaxUserIp.h"
@@ -112,7 +112,7 @@
  * 1 : Match
  */
 int
-ACLMaxUserIP::match(AuthUserRequest::Pointer auth_user_request, Ip::Address const &src_addr)
+ACLMaxUserIP::match(Auth::UserRequest::Pointer auth_user_request, Ip::Address const &src_addr)
 {
     /*
      * the logic for flush the ip list when the limit is hit vs keep
diff -u -r -N squid-3.2.0.14/src/auth/AclMaxUserIp.h squid-3.2.0.15/src/auth/AclMaxUserIp.h
--- squid-3.2.0.14/src/auth/AclMaxUserIp.h	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/auth/AclMaxUserIp.h	2012-02-06 04:52:31.000000000 +1300
@@ -70,7 +70,7 @@
     static Prototype RegistryProtoype;
     static ACLMaxUserIP RegistryEntry_;
 
-    int match(AuthUserRequest::Pointer, Ip::Address const &);
+    int match(Auth::UserRequest::Pointer, Ip::Address const &);
     char const *class_;
     int maximum;
 
diff -u -r -N squid-3.2.0.14/src/auth/AclProxyAuth.cc squid-3.2.0.15/src/auth/AclProxyAuth.cc
--- squid-3.2.0.14/src/auth/AclProxyAuth.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/auth/AclProxyAuth.cc	2012-02-06 04:52:31.000000000 +1300
@@ -34,7 +34,7 @@
  * Copyright (c) 2003, Robert Collins <robertc@squid-cache.org>
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "auth/AclProxyAuth.h"
 #include "auth/Gadgets.h"
 #include "acl/FilledChecklist.h"
diff -u -r -N squid-3.2.0.14/src/auth/basic/auth_basic.cc squid-3.2.0.15/src/auth/basic/auth_basic.cc
--- squid-3.2.0.14/src/auth/basic/auth_basic.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/auth/basic/auth_basic.cc	2012-02-06 04:52:31.000000000 +1300
@@ -37,7 +37,7 @@
  * See acl.c for access control and client_side.c for auditing */
 
 
-#include "squid.h"
+#include "squid-old.h"
 #include "auth/basic/auth_basic.h"
 #include "auth/basic/Scheme.h"
 #include "auth/basic/User.h"
@@ -95,7 +95,7 @@
 }
 
 void
-Auth::Basic::Config::fixHeader(AuthUserRequest::Pointer auth_user_request, HttpReply *rep, http_hdr_type hdrType, HttpRequest * request)
+Auth::Basic::Config::fixHeader(Auth::UserRequest::Pointer auth_user_request, HttpReply *rep, http_hdr_type hdrType, HttpRequest * request)
 {
     if (authenticateProgram) {
         debugs(29, 9, HERE << "Sending type:" << hdrType << " header: 'Basic realm=\"" << basicAuthRealm << "\"'");
@@ -258,10 +258,10 @@
  * "cannot decode credentials". Use the message field to return a
  * descriptive message to the user.
  */
-AuthUserRequest::Pointer
+Auth::UserRequest::Pointer
 Auth::Basic::Config::decode(char const *proxy_auth)
 {
-    AuthUserRequest::Pointer auth_user_request = dynamic_cast<AuthUserRequest*>(new AuthBasicUserRequest);
+    Auth::UserRequest::Pointer auth_user_request = dynamic_cast<Auth::UserRequest*>(new Auth::Basic::UserRequest);
     /* decode the username */
 
     // retrieve the cleartext (in a dynamically allocated char*)
diff -u -r -N squid-3.2.0.14/src/auth/basic/auth_basic.h squid-3.2.0.15/src/auth/basic/auth_basic.h
--- squid-3.2.0.14/src/auth/basic/auth_basic.h	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/auth/basic/auth_basic.h	2012-02-06 04:52:31.000000000 +1300
@@ -19,7 +19,7 @@
 
 public:
     BasicAuthQueueNode *next;
-    AuthUserRequest::Pointer auth_user_request;
+    Auth::UserRequest::Pointer auth_user_request;
     RH *handler;
     void *data;
 };
@@ -37,14 +37,14 @@
     ~Config();
     virtual bool active() const;
     virtual bool configured() const;
-    virtual AuthUserRequest::Pointer decode(char const *proxy_auth);
+    virtual Auth::UserRequest::Pointer decode(char const *proxy_auth);
     virtual void done();
     virtual void rotateHelpers();
     virtual void dump(StoreEntry *, const char *, Auth::Config *);
-    virtual void fixHeader(AuthUserRequest::Pointer, HttpReply *, http_hdr_type, HttpRequest *);
+    virtual void fixHeader(Auth::UserRequest::Pointer, HttpReply *, http_hdr_type, HttpRequest *);
     virtual void init(Auth::Config *);
     virtual void parse(Auth::Config *, int, char *);
-    void decode(char const *httpAuthHeader, AuthUserRequest::Pointer);
+    void decode(char const *httpAuthHeader, Auth::UserRequest::Pointer);
     virtual void registerWithCacheManager(void);
     virtual const char * type() const;
 
diff -u -r -N squid-3.2.0.14/src/auth/basic/Scheme.cc squid-3.2.0.15/src/auth/basic/Scheme.cc
--- squid-3.2.0.14/src/auth/basic/Scheme.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/auth/basic/Scheme.cc	2012-02-06 04:52:31.000000000 +1300
@@ -30,7 +30,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 #include "auth/basic/Scheme.h"
 #include "helper.h"
 
diff -u -r -N squid-3.2.0.14/src/auth/basic/User.cc squid-3.2.0.15/src/auth/basic/User.cc
--- squid-3.2.0.14/src/auth/basic/User.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/auth/basic/User.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "config.h"
+#include "squid.h"
 #include "auth/basic/auth_basic.h"
 #include "auth/basic/User.h"
 #include "Debug.h"
diff -u -r -N squid-3.2.0.14/src/auth/basic/User.h squid-3.2.0.15/src/auth/basic/User.h
--- squid-3.2.0.14/src/auth/basic/User.h	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/auth/basic/User.h	2012-02-06 04:52:31.000000000 +1300
@@ -34,7 +34,7 @@
     BasicAuthQueueNode *auth_queue;
 
 private:
-    AuthUserRequest::Pointer currentRequest;
+    Auth::UserRequest::Pointer currentRequest;
 };
 
 MEMPROXY_CLASS_INLINE(Auth::Basic::User);
diff -u -r -N squid-3.2.0.14/src/auth/basic/UserRequest.cc squid-3.2.0.15/src/auth/basic/UserRequest.cc
--- squid-3.2.0.14/src/auth/basic/UserRequest.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/auth/basic/UserRequest.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "config.h"
+#include "squid.h"
 #include "auth/basic/auth_basic.h"
 #include "auth/basic/User.h"
 #include "auth/basic/UserRequest.h"
@@ -12,7 +12,7 @@
 #endif
 
 int
-AuthBasicUserRequest::authenticated() const
+Auth::Basic::UserRequest::authenticated() const
 {
     Auth::Basic::User const *basic_auth = dynamic_cast<Auth::Basic::User const *>(user().getRaw());
 
@@ -25,7 +25,7 @@
 /* log a basic user in
  */
 void
-AuthBasicUserRequest::authenticate(HttpRequest * request, ConnStateData * conn, http_hdr_type type)
+Auth::Basic::UserRequest::authenticate(HttpRequest * request, ConnStateData * conn, http_hdr_type type)
 {
     assert(user() != NULL);
 
@@ -50,9 +50,9 @@
 }
 
 Auth::Direction
-AuthBasicUserRequest::module_direction()
+Auth::Basic::UserRequest::module_direction()
 {
-    /* null auth_user is checked for by AuthUserRequest::direction() */
+    /* null auth_user is checked for by Auth::UserRequest::direction() */
     if (user()->auth_type != Auth::AUTH_BASIC)
         return Auth::CRED_ERROR;
 
@@ -77,7 +77,7 @@
 
 /* send the initial data to a basic authenticator module */
 void
-AuthBasicUserRequest::module_start(RH * handler, void *data)
+Auth::Basic::UserRequest::module_start(RH * handler, void *data)
 {
     assert(user()->auth_type == Auth::AUTH_BASIC);
     Auth::Basic::User *basic_auth = dynamic_cast<Auth::Basic::User *>(user().getRaw());
@@ -129,12 +129,12 @@
         debugs(9, DBG_CRITICAL, "ERROR: Basic Authentication Failure. user:password exceeds " << sizeof(buf) << " bytes.");
         handler(data, NULL);
     } else
-        helperSubmit(basicauthenticators, buf, AuthBasicUserRequest::HandleReply,
+        helperSubmit(basicauthenticators, buf, Auth::Basic::UserRequest::HandleReply,
                      new Auth::StateData(this, handler, data));
 }
 
 void
-AuthBasicUserRequest::HandleReply(void *data, char *reply)
+Auth::Basic::UserRequest::HandleReply(void *data, char *reply)
 {
     Auth::StateData *r = static_cast<Auth::StateData *>(data);
     BasicAuthQueueNode *tmpnode;
diff -u -r -N squid-3.2.0.14/src/auth/basic/UserRequest.h squid-3.2.0.15/src/auth/basic/UserRequest.h
--- squid-3.2.0.14/src/auth/basic/UserRequest.h	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/auth/basic/UserRequest.h	2012-02-06 04:52:31.000000000 +1300
@@ -1,22 +1,27 @@
 #ifndef _SQUID_SRC_AUTH_BASIC_USERREQUEST_H
 #define _SQUID_SRC_AUTH_BASIC_USERREQUEST_H
 
-#include "MemPool.h"
 #include "auth/UserRequest.h"
+#include "MemPool.h"
 
 class ConnStateData;
 class HttpRequest;
 
-/* follows the http request around */
+namespace Auth
+{
 
-class AuthBasicUserRequest : public AuthUserRequest
+namespace Basic
 {
 
+/* follows the http request around */
+
+class UserRequest : public Auth::UserRequest
+{
 public:
-    MEMPROXY_CLASS(AuthBasicUserRequest);
+    MEMPROXY_CLASS(Auth::Basic::UserRequest);
 
-    AuthBasicUserRequest() {};
-    virtual ~AuthBasicUserRequest() { assert(RefCountCount()==0); };
+    UserRequest() {}
+    virtual ~UserRequest() { assert(RefCountCount()==0); }
 
     virtual int authenticated() const;
     virtual void authenticate(HttpRequest * request, ConnStateData *conn, http_hdr_type type);
@@ -27,6 +32,9 @@
     static HLPCB HandleReply;
 };
 
-MEMPROXY_CLASS_INLINE(AuthBasicUserRequest);
+} // namespace Basic
+} // namespace Auth
+
+MEMPROXY_CLASS_INLINE(Auth::Basic::UserRequest);
 
 #endif /* _SQUID_SRC_AUTH_BASIC_USERREQUEST_H */
diff -u -r -N squid-3.2.0.14/src/auth/Config.cc squid-3.2.0.15/src/auth/Config.cc
--- squid-3.2.0.14/src/auth/Config.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/auth/Config.cc	2012-02-06 04:52:31.000000000 +1300
@@ -32,7 +32,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "auth/Config.h"
 #include "auth/UserRequest.h"
 
@@ -45,7 +45,7 @@
  * It may be a cached AuthUser or a new Unauthenticated object.
  * It may also be NULL reflecting that no user could be created.
  */
-AuthUserRequest::Pointer
+Auth::UserRequest::Pointer
 Auth::Config::CreateAuthUser(const char *proxy_auth)
 {
     assert(proxy_auth != NULL);
diff -u -r -N squid-3.2.0.14/src/auth/Config.h squid-3.2.0.15/src/auth/Config.h
--- squid-3.2.0.14/src/auth/Config.h	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/auth/Config.h	2012-02-06 04:52:31.000000000 +1300
@@ -63,7 +63,7 @@
 {
 
 public:
-    static AuthUserRequest::Pointer CreateAuthUser(const char *proxy_auth);
+    static UserRequest::Pointer CreateAuthUser(const char *proxy_auth);
 
     static Config *Find(const char *proxy_auth);
     Config() : authenticateChildren(20), authenticateProgram(NULL) {}
@@ -83,12 +83,12 @@
      \par
      * Responsible for decoding the passed authentication header, creating or
      * linking to a AuthUser object and for storing any needed details to complete
-     * authentication in AuthUserRequest::authenticate().
+     * authentication in Auth::UserRequest::authenticate().
      *
      \param proxy_auth	Login Pattern to parse.
      \retval *		Details needed to authenticate.
      */
-    virtual AuthUserRequest::Pointer decode(char const *proxy_auth) = 0;
+    virtual UserRequest::Pointer decode(char const *proxy_auth) = 0;
 
     /**
      * squid is finished with this config, release any unneeded resources.
@@ -122,7 +122,7 @@
     virtual void dump(StoreEntry *, const char *, Config *) = 0;
 
     /** add headers as needed when challenging for auth */
-    virtual void fixHeader(AuthUserRequest::Pointer, HttpReply *, http_hdr_type, HttpRequest *) = 0;
+    virtual void fixHeader(UserRequest::Pointer, HttpReply *, http_hdr_type, HttpRequest *) = 0;
 
     /** prepare to handle requests */
     virtual void init(Config *) = 0;
diff -u -r -N squid-3.2.0.14/src/auth/CredentialState.cc squid-3.2.0.15/src/auth/CredentialState.cc
--- squid-3.2.0.14/src/auth/CredentialState.cc	2011-12-13 01:29:28.000000000 +1300
+++ squid-3.2.0.15/src/auth/CredentialState.cc	2012-02-06 06:02:47.000000000 +1300
@@ -1,7 +1,7 @@
 /*
  * Auto-Generated File. Changes will be destroyed.
  */
-#include "config.h"
+#include "squid.h"
 #include "auth/CredentialState.h"
 namespace Auth
 {
diff -u -r -N squid-3.2.0.14/src/auth/digest/auth_digest.cc squid-3.2.0.15/src/auth/digest/auth_digest.cc
--- squid-3.2.0.14/src/auth/digest/auth_digest.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/auth/digest/auth_digest.cc	2012-02-06 04:52:31.000000000 +1300
@@ -37,7 +37,7 @@
  * See acl.c for access control and client_side.c for auditing */
 
 
-#include "squid.h"
+#include "squid-old.h"
 #include "rfc2617.h"
 #include "auth/digest/auth_digest.h"
 #include "auth/digest/Scheme.h"
@@ -542,7 +542,7 @@
 
 /* add the [www-|Proxy-]authenticate header on a 407 or 401 reply */
 void
-Auth::Digest::Config::fixHeader(AuthUserRequest::Pointer auth_user_request, HttpReply *rep, http_hdr_type hdrType, HttpRequest * request)
+Auth::Digest::Config::fixHeader(Auth::UserRequest::Pointer auth_user_request, HttpReply *rep, http_hdr_type hdrType, HttpRequest * request)
 {
     if (!authenticateProgram)
         return;
@@ -550,8 +550,7 @@
     int stale = 0;
 
     if (auth_user_request != NULL) {
-        AuthDigestUserRequest *digest_request;
-        digest_request = dynamic_cast<AuthDigestUserRequest*>(auth_user_request.getRaw());
+        Auth::Digest::UserRequest *digest_request = dynamic_cast<Auth::Digest::UserRequest*>(auth_user_request.getRaw());
         assert (digest_request != NULL);
 
         stale = !digest_request->flags.invalid_password;
@@ -560,7 +559,7 @@
     /* on a 407 or 401 we always use a new nonce */
     digest_nonce_h *nonce = authenticateDigestNonceNew();
 
-    debugs(29, 9, "authenticateFixHeader: Sending type:" << hdrType <<
+    debugs(29, 9, HERE << "Sending type:" << hdrType <<
            " header: 'Digest realm=\"" << digestAuthRealm << "\", nonce=\"" <<
            authenticateDigestNonceNonceb64(nonce) << "\", qop=\"" << QOP_AUTH <<
            "\", stale=" << (stale ? "true" : "false"));
@@ -757,8 +756,8 @@
 }
 
 /* setup the necessary info to log the username */
-static AuthUserRequest::Pointer
-authDigestLogUsername(char *username, AuthUserRequest::Pointer auth_user_request)
+static Auth::UserRequest::Pointer
+authDigestLogUsername(char *username, Auth::UserRequest::Pointer auth_user_request)
 {
     assert(auth_user_request != NULL);
 
@@ -778,7 +777,7 @@
  * Decode a Digest [Proxy-]Auth string, placing the results in the passed
  * Auth_user structure.
  */
-AuthUserRequest::Pointer
+Auth::UserRequest::Pointer
 Auth::Digest::Config::decode(char const *proxy_auth)
 {
     const char *item;
@@ -790,7 +789,7 @@
 
     debugs(29, 9, "authenticateDigestDecodeAuth: beginning");
 
-    AuthDigestUserRequest *digest_request = new AuthDigestUserRequest();
+    Auth::Digest::UserRequest *digest_request = new Auth::Digest::UserRequest();
 
     /* trim DIGEST from string */
 
@@ -838,14 +837,14 @@
                 }
             } else if (*p == '"') {
                 if (!httpHeaderParseQuotedString(p, vlen, &value)) {
-                    debugs(29, 9, "authDigestDecodeAuth: Failed to parse attribute '" << item << "' in '" << temp << "'");
+                    debugs(29, 9, HERE << "Failed to parse attribute '" << item << "' in '" << temp << "'");
                     continue;
                 }
             } else {
                 value.limitInit(p, vlen);
             }
         } else {
-            debugs(29, 9, "authDigestDecodeAuth: Failed to parse attribute '" << item << "' in '" << temp << "'");
+            debugs(29, 9, HERE << "Failed to parse attribute '" << item << "' in '" << temp << "'");
             continue;
         }
 
@@ -856,61 +855,61 @@
         case DIGEST_USERNAME:
             safe_free(username);
             username = xstrndup(value.rawBuf(), value.size() + 1);
-            debugs(29, 9, "authDigestDecodeAuth: Found Username '" << username << "'");
+            debugs(29, 9, HERE << "Found Username '" << username << "'");
             break;
 
         case DIGEST_REALM:
             safe_free(digest_request->realm);
             digest_request->realm = xstrndup(value.rawBuf(), value.size() + 1);
-            debugs(29, 9, "authDigestDecodeAuth: Found realm '" << digest_request->realm << "'");
+            debugs(29, 9, HERE << "Found realm '" << digest_request->realm << "'");
             break;
 
         case DIGEST_QOP:
             safe_free(digest_request->qop);
             digest_request->qop = xstrndup(value.rawBuf(), value.size() + 1);
-            debugs(29, 9, "authDigestDecodeAuth: Found qop '" << digest_request->qop << "'");
+            debugs(29, 9, HERE << "Found qop '" << digest_request->qop << "'");
             break;
 
         case DIGEST_ALGORITHM:
             safe_free(digest_request->algorithm);
             digest_request->algorithm = xstrndup(value.rawBuf(), value.size() + 1);
-            debugs(29, 9, "authDigestDecodeAuth: Found algorithm '" << digest_request->algorithm << "'");
+            debugs(29, 9, HERE << "Found algorithm '" << digest_request->algorithm << "'");
             break;
 
         case DIGEST_URI:
             safe_free(digest_request->uri);
             digest_request->uri = xstrndup(value.rawBuf(), value.size() + 1);
-            debugs(29, 9, "authDigestDecodeAuth: Found uri '" << digest_request->uri << "'");
+            debugs(29, 9, HERE << "Found uri '" << digest_request->uri << "'");
             break;
 
         case DIGEST_NONCE:
             safe_free(digest_request->nonceb64);
             digest_request->nonceb64 = xstrndup(value.rawBuf(), value.size() + 1);
-            debugs(29, 9, "authDigestDecodeAuth: Found nonce '" << digest_request->nonceb64 << "'");
+            debugs(29, 9, HERE << "Found nonce '" << digest_request->nonceb64 << "'");
             break;
 
         case DIGEST_NC:
             if (value.size() != 8) {
-                debugs(29, 9, "authDigestDecodeAuth: Invalid nc '" << value << "' in '" << temp << "'");
+                debugs(29, 9, HERE << "Invalid nc '" << value << "' in '" << temp << "'");
             }
             xstrncpy(digest_request->nc, value.rawBuf(), value.size() + 1);
-            debugs(29, 9, "authDigestDecodeAuth: Found noncecount '" << digest_request->nc << "'");
+            debugs(29, 9, HERE << "Found noncecount '" << digest_request->nc << "'");
             break;
 
         case DIGEST_CNONCE:
             safe_free(digest_request->cnonce);
             digest_request->cnonce = xstrndup(value.rawBuf(), value.size() + 1);
-            debugs(29, 9, "authDigestDecodeAuth: Found cnonce '" << digest_request->cnonce << "'");
+            debugs(29, 9, HERE << "Found cnonce '" << digest_request->cnonce << "'");
             break;
 
         case DIGEST_RESPONSE:
             safe_free(digest_request->response);
             digest_request->response = xstrndup(value.rawBuf(), value.size() + 1);
-            debugs(29, 9, "authDigestDecodeAuth: Found response '" << digest_request->response << "'");
+            debugs(29, 9, HERE << "Found response '" << digest_request->response << "'");
             break;
 
         default:
-            debugs(29, 3, "authDigestDecodeAuth: Unknown attribute '" << item << "' in '" << temp << "'");
+            debugs(29, 3, HERE << "Unknown attribute '" << item << "' in '" << temp << "'");
             break;
         }
     }
@@ -933,7 +932,7 @@
 
     /* do we have a username ? */
     if (!username || username[0] == '\0') {
-        debugs(29, 2, "authenticateDigestDecode: Empty or not present username");
+        debugs(29, 2, HERE << "Empty or not present username");
         return authDigestLogUsername(username, digest_request);
     }
 
@@ -942,32 +941,32 @@
      * have been redone
      */
     if (strchr(username, '"')) {
-        debugs(29, 2, "authenticateDigestDecode: Unacceptable username '" << username << "'");
+        debugs(29, 2, HERE << "Unacceptable username '" << username << "'");
         return authDigestLogUsername(username, digest_request);
     }
 
     /* do we have a realm ? */
     if (!digest_request->realm || digest_request->realm[0] == '\0') {
-        debugs(29, 2, "authenticateDigestDecode: Empty or not present realm");
+        debugs(29, 2, HERE << "Empty or not present realm");
         return authDigestLogUsername(username, digest_request);
     }
 
     /* and a nonce? */
     if (!digest_request->nonceb64 || digest_request->nonceb64[0] == '\0') {
-        debugs(29, 2, "authenticateDigestDecode: Empty or not present nonce");
+        debugs(29, 2, HERE << "Empty or not present nonce");
         return authDigestLogUsername(username, digest_request);
     }
 
     /* we can't check the URI just yet. We'll check it in the
      * authenticate phase, but needs to be given */
     if (!digest_request->uri || digest_request->uri[0] == '\0') {
-        debugs(29, 2, "authenticateDigestDecode: Missing URI field");
+        debugs(29, 2, HERE << "Missing URI field");
         return authDigestLogUsername(username, digest_request);
     }
 
     /* is the response the correct length? */
     if (!digest_request->response || strlen(digest_request->response) != 32) {
-        debugs(29, 2, "authenticateDigestDecode: Response length invalid");
+        debugs(29, 2, HERE << "Response length invalid");
         return authDigestLogUsername(username, digest_request);
     }
 
@@ -976,7 +975,7 @@
         digest_request->algorithm = xstrndup("MD5", 4);
     else if (strcmp(digest_request->algorithm, "MD5")
              && strcmp(digest_request->algorithm, "MD5-sess")) {
-        debugs(29, 2, "authenticateDigestDecode: invalid algorithm specified!");
+        debugs(29, 2, HERE << "invalid algorithm specified!");
         return authDigestLogUsername(username, digest_request);
     }
 
@@ -986,25 +985,25 @@
         /* check the qop is what we expected. */
         if (strcmp(digest_request->qop, QOP_AUTH) != 0) {
             /* we received a qop option we didn't send */
-            debugs(29, 2, "authenticateDigestDecode: Invalid qop option received");
+            debugs(29, 2, HERE << "Invalid qop option received");
             return authDigestLogUsername(username, digest_request);
         }
 
         /* check cnonce */
         if (!digest_request->cnonce || digest_request->cnonce[0] == '\0') {
-            debugs(29, 2, "authenticateDigestDecode: Missing cnonce field");
+            debugs(29, 2, HERE << "Missing cnonce field");
             return authDigestLogUsername(username, digest_request);
         }
 
         /* check nc */
         if (strlen(digest_request->nc) != 8 || strspn(digest_request->nc, "0123456789abcdefABCDEF") != 8) {
-            debugs(29, 2, "authenticateDigestDecode: invalid nonce count");
+            debugs(29, 2, HERE << "invalid nonce count");
             return authDigestLogUsername(username, digest_request);
         }
     } else {
         /* cnonce and nc both require qop */
         if (digest_request->cnonce || digest_request->nc) {
-            debugs(29, 2, "authenticateDigestDecode: missing qop!");
+            debugs(29, 2, HERE << "missing qop!");
             return authDigestLogUsername(username, digest_request);
         }
     }
@@ -1015,7 +1014,7 @@
     nonce = authenticateDigestNonceFindNonce(digest_request->nonceb64);
     if (!nonce) {
         /* we couldn't find a matching nonce! */
-        debugs(29, 2, "authenticateDigestDecode: Unexpected or invalid nonce received");
+        debugs(29, 2, HERE << "Unexpected or invalid nonce received");
         if (digest_request->user() != NULL)
             digest_request->user()->credentials(Auth::Failed);
         return authDigestLogUsername(username, digest_request);
@@ -1026,7 +1025,7 @@
 
     /* check that we're not being hacked / the username hasn't changed */
     if (nonce->user && strcmp(username, nonce->user->username())) {
-        debugs(29, 2, "authenticateDigestDecode: Username for the nonce does not equal the username for the request");
+        debugs(29, 2, HERE << "Username for the nonce does not equal the username for the request");
         return authDigestLogUsername(username, digest_request);
     }
 
@@ -1042,7 +1041,7 @@
 
     if ((auth_user = authDigestUserFindUsername(username)) == NULL) {
         /* the user doesn't exist in the username cache yet */
-        debugs(29, 9, "authDigestDecodeAuth: Creating new digest user '" << username << "'");
+        debugs(29, 9, HERE << "Creating new digest user '" << username << "'");
         digest_user = new Auth::Digest::User(this);
         /* auth_user is a parent */
         auth_user = digest_user;
@@ -1062,7 +1061,7 @@
          */
         authDigestUserLinkNonce(digest_user, nonce);
     } else {
-        debugs(29, 9, "authDigestDecodeAuth: Found user '" << username << "' in the user cache as '" << auth_user << "'");
+        debugs(29, 9, HERE << "Found user '" << username << "' in the user cache as '" << auth_user << "'");
         digest_user = static_cast<Auth::Digest::User *>(auth_user.getRaw());
         xfree(username);
     }
@@ -1071,7 +1070,7 @@
     assert(digest_request != NULL);
 
     digest_request->user(digest_user);
-    debugs(29, 9, "username = '" << digest_user->username() << "'\nrealm = '" <<
+    debugs(29, 9, HERE << "username = '" << digest_user->username() << "'\nrealm = '" <<
            digest_request->realm << "'\nqop = '" << digest_request->qop <<
            "'\nalgorithm = '" << digest_request->algorithm << "'\nuri = '" <<
            digest_request->uri << "'\nnonce = '" << digest_request->nonceb64 <<
diff -u -r -N squid-3.2.0.14/src/auth/digest/auth_digest.h squid-3.2.0.15/src/auth/digest/auth_digest.h
--- squid-3.2.0.14/src/auth/digest/auth_digest.h	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/auth/digest/auth_digest.h	2012-02-06 04:52:31.000000000 +1300
@@ -69,11 +69,11 @@
     Config();
     virtual bool active() const;
     virtual bool configured() const;
-    virtual AuthUserRequest::Pointer decode(char const *proxy_auth);
+    virtual Auth::UserRequest::Pointer decode(char const *proxy_auth);
     virtual void done();
     virtual void rotateHelpers();
     virtual void dump(StoreEntry *, const char *, Auth::Config *);
-    virtual void fixHeader(AuthUserRequest::Pointer, HttpReply *, http_hdr_type, HttpRequest *);
+    virtual void fixHeader(Auth::UserRequest::Pointer, HttpReply *, http_hdr_type, HttpRequest *);
     virtual void init(Auth::Config *);
     virtual void parse(Auth::Config *, int, char *);
     virtual void registerWithCacheManager(void);
diff -u -r -N squid-3.2.0.14/src/auth/digest/Scheme.cc squid-3.2.0.15/src/auth/digest/Scheme.cc
--- squid-3.2.0.14/src/auth/digest/Scheme.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/auth/digest/Scheme.cc	2012-02-06 04:52:31.000000000 +1300
@@ -30,7 +30,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 #include "auth/digest/Scheme.h"
 #include "helper.h"
 
diff -u -r -N squid-3.2.0.14/src/auth/digest/User.cc squid-3.2.0.15/src/auth/digest/User.cc
--- squid-3.2.0.14/src/auth/digest/User.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/auth/digest/User.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "config.h"
+#include "squid.h"
 #include "auth/digest/auth_digest.h"
 #include "auth/digest/User.h"
 #include "Debug.h"
diff -u -r -N squid-3.2.0.14/src/auth/digest/UserRequest.cc squid-3.2.0.15/src/auth/digest/UserRequest.cc
--- squid-3.2.0.14/src/auth/digest/UserRequest.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/auth/digest/UserRequest.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "config.h"
+#include "squid.h"
 #include "auth/digest/auth_digest.h"
 #include "auth/digest/User.h"
 #include "auth/digest/UserRequest.h"
@@ -8,7 +8,7 @@
 #include "HttpRequest.h"
 #include "SquidTime.h"
 
-AuthDigestUserRequest::AuthDigestUserRequest() :
+Auth::Digest::UserRequest::UserRequest() :
         nonceb64(NULL),
         cnonce(NULL),
         realm(NULL),
@@ -25,7 +25,7 @@
  * Delete the digest request structure.
  * Does NOT delete related AuthUser structures
  */
-AuthDigestUserRequest::~AuthDigestUserRequest()
+Auth::Digest::UserRequest::~UserRequest()
 {
     assert(RefCountCount()==0);
 
@@ -44,7 +44,7 @@
 }
 
 int
-AuthDigestUserRequest::authenticated() const
+Auth::Digest::UserRequest::authenticated() const
 {
     if (user() != NULL && user()->credentials() == Auth::Ok)
         return 1;
@@ -55,7 +55,7 @@
 /** log a digest user in
  */
 void
-AuthDigestUserRequest::authenticate(HttpRequest * request, ConnStateData * conn, http_hdr_type type)
+Auth::Digest::UserRequest::authenticate(HttpRequest * request, ConnStateData * conn, http_hdr_type type)
 {
     HASHHEX SESSIONKEY;
     HASHHEX HA2 = "";
@@ -71,7 +71,7 @@
     Auth::Digest::User *digest_user = dynamic_cast<Auth::Digest::User*>(auth_user.getRaw());
     assert(digest_user != NULL);
 
-    AuthDigestUserRequest *digest_request = this;
+    Auth::Digest::UserRequest *digest_request = this;
 
     /* do we have the HA1 */
     if (!digest_user->HA1created) {
@@ -131,7 +131,7 @@
                 }
 
                 if (last_broken_addr != request->client_addr) {
-                    debugs(29, 1, "\nDigest POST bug detected from " <<
+                    debugs(29, DBG_IMPORTANT, "Digest POST bug detected from " <<
                            request->client_addr << " using '" <<
                            (useragent ? useragent : "-") <<
                            "'. Please upgrade browser. See Bug #630 for details.");
@@ -148,7 +148,7 @@
 
         /* check for stale nonce */
         if (!authDigestNonceIsValid(digest_request->nonce, digest_request->nc)) {
-            debugs(29, 3, "authenticateDigestAuthenticateuser: user '" << auth_user->username() << "' validated OK but nonce stale");
+            debugs(29, 3, HERE << "user '" << auth_user->username() << "' validated OK but nonce stale");
             auth_user->credentials(Auth::Failed);
             digest_request->setDenyMessage("Stale nonce");
             return;
@@ -158,7 +158,7 @@
     auth_user->credentials(Auth::Ok);
 
     /* password was checked and did match */
-    debugs(29, 4, "authenticateDigestAuthenticateuser: user '" << auth_user->username() << "' validated OK");
+    debugs(29, 4, HERE << "user '" << auth_user->username() << "' validated OK");
 
     /* auth_user is now linked, we reset these values
      * after external auth occurs anyway */
@@ -167,7 +167,7 @@
 }
 
 Auth::Direction
-AuthDigestUserRequest::module_direction()
+Auth::Digest::UserRequest::module_direction()
 {
     if (user()->auth_type != Auth::AUTH_DIGEST)
         return Auth::CRED_ERROR;
@@ -191,7 +191,7 @@
 }
 
 void
-AuthDigestUserRequest::addAuthenticationInfoHeader(HttpReply * rep, int accel)
+Auth::Digest::UserRequest::addAuthenticationInfoHeader(HttpReply * rep, int accel)
 {
     http_hdr_type type;
 
@@ -211,14 +211,14 @@
 
     if ((static_cast<Auth::Digest::Config*>(Auth::Config::Find("digest"))->authenticateProgram) && authDigestNonceLastRequest(nonce)) {
         flags.authinfo_sent = 1;
-        debugs(29, 9, "authDigestAddHead: Sending type:" << type << " header: 'nextnonce=\"" << authenticateDigestNonceNonceb64(nonce) << "\"");
+        debugs(29, 9, HERE << "Sending type:" << type << " header: 'nextnonce=\"" << authenticateDigestNonceNonceb64(nonce) << "\"");
         httpHeaderPutStrf(&rep->header, type, "nextnonce=\"%s\"", authenticateDigestNonceNonceb64(nonce));
     }
 }
 
 #if WAITING_FOR_TE
 void
-AuthDigestUserRequest::addAuthenticationInfoTrailer(HttpReply * rep, int accel)
+Auth::Digest::UserRequest::addAuthenticationInfoTrailer(HttpReply * rep, int accel)
 {
     int type;
 
@@ -237,7 +237,7 @@
     type = accel ? HDR_AUTHENTICATION_INFO : HDR_PROXY_AUTHENTICATION_INFO;
 
     if ((static_cast<Auth::Digest::Config*>(digestScheme::GetInstance()->getConfig())->authenticate) && authDigestNonceLastRequest(nonce)) {
-        debugs(29, 9, "authDigestAddTrailer: Sending type:" << type << " header: 'nextnonce=\"" << authenticateDigestNonceNonceb64(nonce) << "\"");
+        debugs(29, 9, HERE << "Sending type:" << type << " header: 'nextnonce=\"" << authenticateDigestNonceNonceb64(nonce) << "\"");
         httpTrailerPutStrf(&rep->header, type, "nextnonce=\"%s\"", authenticateDigestNonceNonceb64(nonce));
     }
 }
@@ -245,12 +245,12 @@
 
 /* send the initial data to a digest authenticator module */
 void
-AuthDigestUserRequest::module_start(RH * handler, void *data)
+Auth::Digest::UserRequest::module_start(RH * handler, void *data)
 {
     char buf[8192];
 
     assert(user() != NULL && user()->auth_type == Auth::AUTH_DIGEST);
-    debugs(29, 9, "authenticateStart: '\"" << user()->username() << "\":\"" << realm << "\"'");
+    debugs(29, 9, HERE << "'\"" << user()->username() << "\":\"" << realm << "\"'");
 
     if (static_cast<Auth::Digest::Config*>(Auth::Config::Find("digest"))->authenticateProgram == NULL) {
         debugs(29, DBG_CRITICAL, "ERROR: No Digest authentication program configured.");
@@ -266,12 +266,12 @@
         snprintf(buf, 8192, "\"%s\":\"%s\"\n", user()->username(), realm);
     }
 
-    helperSubmit(digestauthenticators, buf, AuthDigestUserRequest::HandleReply,
+    helperSubmit(digestauthenticators, buf, Auth::Digest::UserRequest::HandleReply,
                  new Auth::StateData(this, handler, data));
 }
 
 void
-AuthDigestUserRequest::HandleReply(void *data, char *reply)
+Auth::Digest::UserRequest::HandleReply(void *data, char *reply)
 {
     Auth::StateData *replyData = static_cast<Auth::StateData *>(data);
     char *t = NULL;
@@ -287,11 +287,11 @@
     }
 
     assert(replyData->auth_user_request != NULL);
-    AuthUserRequest::Pointer auth_user_request = replyData->auth_user_request;
+    Auth::UserRequest::Pointer auth_user_request = replyData->auth_user_request;
 
     if (reply && (strncasecmp(reply, "ERR", 3) == 0)) {
         /* allow this because the digest_request pointer is purely local */
-        AuthDigestUserRequest *digest_request = dynamic_cast<AuthDigestUserRequest *>(auth_user_request.getRaw());
+        Auth::Digest::UserRequest *digest_request = dynamic_cast<Auth::Digest::UserRequest *>(auth_user_request.getRaw());
         assert(digest_request);
 
         digest_request->user()->credentials(Auth::Failed);
diff -u -r -N squid-3.2.0.14/src/auth/digest/UserRequest.h squid-3.2.0.15/src/auth/digest/UserRequest.h
--- squid-3.2.0.14/src/auth/digest/UserRequest.h	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/auth/digest/UserRequest.h	2012-02-06 04:52:31.000000000 +1300
@@ -9,21 +9,26 @@
 class HttpReply;
 class HttpRequest;
 
+namespace Auth
+{
+namespace Digest
+{
+
 /**
- * The AuthDigestUserRequest structure is what follows the http_request around
+ * The UserRequest structure is what follows the http_request around
  */
-class AuthDigestUserRequest : public AuthUserRequest
+class UserRequest : public Auth::UserRequest
 {
 
 public:
-    MEMPROXY_CLASS(AuthDigestUserRequest);
+    MEMPROXY_CLASS(Auth::Digest::UserRequest);
 
-    AuthDigestUserRequest();
-    virtual ~AuthDigestUserRequest();
+    UserRequest();
+    virtual ~UserRequest();
 
     virtual int authenticated() const;
     virtual void authenticate(HttpRequest * request, ConnStateData * conn, http_hdr_type type);
-    virtual Auth::Direction module_direction();
+    virtual Direction module_direction();
     virtual void addAuthenticationInfoHeader(HttpReply * rep, int accel);
 #if WAITING_FOR_TE
     virtual void addAuthenticationInfoTrailer(HttpReply * rep, int accel);
@@ -53,6 +58,9 @@
     static HLPCB HandleReply;
 };
 
-MEMPROXY_CLASS_INLINE(AuthDigestUserRequest);
+} // namespace Digest
+} // namespace Auth
+
+MEMPROXY_CLASS_INLINE(Auth::Digest::UserRequest);
 
 #endif /* _SQUID_SRC_AUTH_DIGEST_USERREQUEST_H */
diff -u -r -N squid-3.2.0.14/src/auth/Gadgets.cc squid-3.2.0.15/src/auth/Gadgets.cc
--- squid-3.2.0.14/src/auth/Gadgets.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/auth/Gadgets.cc	2012-02-06 04:52:31.000000000 +1300
@@ -36,7 +36,7 @@
  * They DO NOT perform access control or auditing.
  * See acl.c for access control and client_side.c for auditing */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "acl/Acl.h"
 #include "acl/FilledChecklist.h"
 #include "client_side.h"
diff -u -r -N squid-3.2.0.14/src/auth/negotiate/auth_negotiate.cc squid-3.2.0.15/src/auth/negotiate/auth_negotiate.cc
--- squid-3.2.0.14/src/auth/negotiate/auth_negotiate.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/auth/negotiate/auth_negotiate.cc	2012-02-06 04:52:31.000000000 +1300
@@ -37,7 +37,7 @@
  * See acl.c for access control and client_side.c for auditing */
 
 
-#include "squid.h"
+#include "squid-old.h"
 #include "auth/negotiate/auth_negotiate.h"
 #include "auth/Gadgets.h"
 #include "auth/State.h"
@@ -213,10 +213,8 @@
 /* Negotiate Scheme */
 
 void
-Auth::Negotiate::Config::fixHeader(AuthUserRequest::Pointer auth_user_request, HttpReply *rep, http_hdr_type reqType, HttpRequest * request)
+Auth::Negotiate::Config::fixHeader(Auth::UserRequest::Pointer auth_user_request, HttpReply *rep, http_hdr_type reqType, HttpRequest * request)
 {
-    AuthNegotiateUserRequest *negotiate_request;
-
     if (!authenticateProgram)
         return;
 
@@ -235,7 +233,7 @@
             request->flags.proxy_keepalive = 0;
         }
     } else {
-        negotiate_request = dynamic_cast<AuthNegotiateUserRequest *>(auth_user_request.getRaw());
+        Auth::Negotiate::UserRequest *negotiate_request = dynamic_cast<Auth::Negotiate::UserRequest *>(auth_user_request.getRaw());
         assert(negotiate_request != NULL);
 
         switch (negotiate_request->user()->credentials()) {
@@ -292,11 +290,11 @@
  * Decode a Negotiate [Proxy-]Auth string, placing the results in the passed
  * Auth_user structure.
  */
-AuthUserRequest::Pointer
+Auth::UserRequest::Pointer
 Auth::Negotiate::Config::decode(char const *proxy_auth)
 {
     Auth::Negotiate::User *newUser = new Auth::Negotiate::User(&negotiateConfig);
-    AuthUserRequest *auth_user_request = new AuthNegotiateUserRequest();
+    Auth::UserRequest *auth_user_request = new Auth::Negotiate::UserRequest();
     assert(auth_user_request->user() == NULL);
 
     auth_user_request->user(newUser);
diff -u -r -N squid-3.2.0.14/src/auth/negotiate/auth_negotiate.h squid-3.2.0.15/src/auth/negotiate/auth_negotiate.h
--- squid-3.2.0.14/src/auth/negotiate/auth_negotiate.h	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/auth/negotiate/auth_negotiate.h	2012-02-06 04:52:31.000000000 +1300
@@ -31,11 +31,11 @@
     Config();
     virtual bool active() const;
     virtual bool configured() const;
-    virtual AuthUserRequest::Pointer decode(char const *proxy_auth);
+    virtual Auth::UserRequest::Pointer decode(char const *proxy_auth);
     virtual void done();
     virtual void rotateHelpers();
     virtual void dump(StoreEntry *, const char *, Auth::Config *);
-    virtual void fixHeader(AuthUserRequest::Pointer, HttpReply *, http_hdr_type, HttpRequest *);
+    virtual void fixHeader(Auth::UserRequest::Pointer, HttpReply *, http_hdr_type, HttpRequest *);
     virtual void init(Auth::Config *);
     virtual void parse(Auth::Config *, int, char *);
     virtual void registerWithCacheManager(void);
diff -u -r -N squid-3.2.0.14/src/auth/negotiate/Scheme.cc squid-3.2.0.15/src/auth/negotiate/Scheme.cc
--- squid-3.2.0.14/src/auth/negotiate/Scheme.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/auth/negotiate/Scheme.cc	2012-02-06 04:52:31.000000000 +1300
@@ -30,7 +30,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 #include "auth/negotiate/Scheme.h"
 #include "helper.h"
 
diff -u -r -N squid-3.2.0.14/src/auth/negotiate/User.cc squid-3.2.0.15/src/auth/negotiate/User.cc
--- squid-3.2.0.14/src/auth/negotiate/User.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/auth/negotiate/User.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "config.h"
+#include "squid.h"
 #include "auth/Config.h"
 #include "auth/negotiate/User.h"
 #include "Debug.h"
diff -u -r -N squid-3.2.0.14/src/auth/negotiate/UserRequest.cc squid-3.2.0.15/src/auth/negotiate/UserRequest.cc
--- squid-3.2.0.14/src/auth/negotiate/UserRequest.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/auth/negotiate/UserRequest.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "config.h"
+#include "squid.h"
 #include "auth/negotiate/auth_negotiate.h"
 #include "auth/negotiate/UserRequest.h"
 #include "auth/State.h"
@@ -8,7 +8,7 @@
 #include "HttpRequest.h"
 #include "SquidTime.h"
 
-AuthNegotiateUserRequest::AuthNegotiateUserRequest()
+Auth::Negotiate::UserRequest::UserRequest()
 {
     waiting=0;
     client_blob=0;
@@ -17,7 +17,7 @@
     request=NULL;
 }
 
-AuthNegotiateUserRequest::~AuthNegotiateUserRequest()
+Auth::Negotiate::UserRequest::~UserRequest()
 {
     assert(RefCountCount()==0);
     safe_free(server_blob);
@@ -32,13 +32,13 @@
 }
 
 const char *
-AuthNegotiateUserRequest::connLastHeader()
+Auth::Negotiate::UserRequest::connLastHeader()
 {
     return NULL;
 }
 
 int
-AuthNegotiateUserRequest::authenticated() const
+Auth::Negotiate::UserRequest::authenticated() const
 {
     if (user() != NULL && user()->credentials() == Auth::Ok) {
         debugs(29, 9, HERE << "user authenticated.");
@@ -50,9 +50,9 @@
 }
 
 Auth::Direction
-AuthNegotiateUserRequest::module_direction()
+Auth::Negotiate::UserRequest::module_direction()
 {
-    /* null auth_user is checked for by AuthUserRequest::direction() */
+    /* null auth_user is checked for by Auth::UserRequest::direction() */
 
     if (waiting || client_blob)
         return Auth::CRED_LOOKUP; /* need helper response to continue */
@@ -79,7 +79,7 @@
 }
 
 void
-AuthNegotiateUserRequest::module_start(RH * handler, void *data)
+Auth::Negotiate::UserRequest::module_start(RH * handler, void *data)
 {
     static char buf[MAX_AUTHTOKEN_LEN];
 
@@ -107,7 +107,7 @@
 
     safe_free(client_blob);
 
-    helperStatefulSubmit(negotiateauthenticators, buf, AuthNegotiateUserRequest::HandleReply,
+    helperStatefulSubmit(negotiateauthenticators, buf, Auth::Negotiate::UserRequest::HandleReply,
                          new Auth::StateData(this, handler, data), authserver);
 }
 
@@ -116,7 +116,7 @@
  * for this request connections use.
  */
 void
-AuthNegotiateUserRequest::releaseAuthServer()
+Auth::Negotiate::UserRequest::releaseAuthServer()
 {
     if (authserver) {
         debugs(29, 6, HERE << "releasing Negotiate auth server '" << authserver << "'");
@@ -128,14 +128,14 @@
 
 /* clear any connection related authentication details */
 void
-AuthNegotiateUserRequest::onConnectionClose(ConnStateData *conn)
+Auth::Negotiate::UserRequest::onConnectionClose(ConnStateData *conn)
 {
     assert(conn != NULL);
 
-    debugs(29, 8, "AuthNegotiateUserRequest::onConnectionClose: closing connection '" << conn << "' (this is '" << this << "')");
+    debugs(29, 8, HERE << "closing connection '" << conn << "' (this is '" << this << "')");
 
     if (conn->auth_user_request == NULL) {
-        debugs(29, 8, "AuthNegotiateUserRequest::onConnectionClose: no auth_user_request");
+        debugs(29, 8, HERE << "no auth_user_request");
         return;
     }
 
@@ -148,7 +148,7 @@
 }
 
 void
-AuthNegotiateUserRequest::authenticate(HttpRequest * aRequest, ConnStateData * conn, http_hdr_type type)
+Auth::Negotiate::UserRequest::authenticate(HttpRequest * aRequest, ConnStateData * conn, http_hdr_type type)
 {
     assert(this);
 
@@ -218,7 +218,7 @@
         break;
 
     case Auth::Ok:
-        fatal("AuthNegotiateUserRequest::authenticate: unexpected auth state DONE! Report a bug to the squid developers.\n");
+        fatal("Auth::Negotiate::UserRequest::authenticate: unexpected auth state DONE! Report a bug to the squid developers.\n");
         break;
 
     case Auth::Failed:
@@ -229,7 +229,7 @@
 }
 
 void
-AuthNegotiateUserRequest::HandleReply(void *data, void *lastserver, char *reply)
+Auth::Negotiate::UserRequest::HandleReply(void *data, void *lastserver, char *reply)
 {
     Auth::StateData *r = static_cast<Auth::StateData *>(data);
 
@@ -248,10 +248,10 @@
         reply = (char *)"BH Internal error";
     }
 
-    AuthUserRequest::Pointer auth_user_request = r->auth_user_request;
+    Auth::UserRequest::Pointer auth_user_request = r->auth_user_request;
     assert(auth_user_request != NULL);
 
-    AuthNegotiateUserRequest *lm_request = dynamic_cast<AuthNegotiateUserRequest *>(auth_user_request.getRaw());
+    Auth::Negotiate::UserRequest *lm_request = dynamic_cast<Auth::Negotiate::UserRequest *>(auth_user_request.getRaw());
     assert(lm_request != NULL);
     assert(lm_request->waiting);
 
@@ -365,7 +365,7 @@
 }
 
 void
-AuthNegotiateUserRequest::addAuthenticationInfoHeader(HttpReply * rep, int accel)
+Auth::Negotiate::UserRequest::addAuthenticationInfoHeader(HttpReply * rep, int accel)
 {
     http_hdr_type type;
 
diff -u -r -N squid-3.2.0.14/src/auth/negotiate/UserRequest.h squid-3.2.0.15/src/auth/negotiate/UserRequest.h
--- squid-3.2.0.14/src/auth/negotiate/UserRequest.h	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/auth/negotiate/UserRequest.h	2012-02-06 04:52:31.000000000 +1300
@@ -9,18 +9,23 @@
 class HttpRequest;
 class helper_stateful_server;
 
+namespace Auth
+{
+namespace Negotiate
+{
+
 /// \ingroup AuthNegotiateAPI
-class AuthNegotiateUserRequest : public AuthUserRequest
+class UserRequest : public Auth::UserRequest
 {
 
 public:
-    MEMPROXY_CLASS(AuthNegotiateUserRequest);
+    MEMPROXY_CLASS(Auth::Negotiate::UserRequest);
 
-    AuthNegotiateUserRequest();
-    virtual ~AuthNegotiateUserRequest();
+    UserRequest();
+    virtual ~UserRequest();
     virtual int authenticated() const;
     virtual void authenticate(HttpRequest * request, ConnStateData * conn, http_hdr_type type);
-    virtual Auth::Direction module_direction();
+    virtual Direction module_direction();
     virtual void onConnectionClose(ConnStateData *);
     virtual void module_start(RH *, void *);
 
@@ -50,6 +55,9 @@
     static HLPSCB HandleReply;
 };
 
-MEMPROXY_CLASS_INLINE(AuthNegotiateUserRequest);
+} // namespace Negotiate
+} // namespace Auth
+
+MEMPROXY_CLASS_INLINE(Auth::Negotiate::UserRequest);
 
 #endif /* _SQUID_SRC_AUTH_NEGOTIATE_USERREQUEST_H */
diff -u -r -N squid-3.2.0.14/src/auth/ntlm/auth_ntlm.cc squid-3.2.0.15/src/auth/ntlm/auth_ntlm.cc
--- squid-3.2.0.14/src/auth/ntlm/auth_ntlm.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/auth/ntlm/auth_ntlm.cc	2012-02-06 04:52:31.000000000 +1300
@@ -37,7 +37,7 @@
  * See acl.c for access control and client_side.c for auditing */
 
 
-#include "squid.h"
+#include "squid-old.h"
 #include "auth/Gadgets.h"
 #include "auth/ntlm/auth_ntlm.h"
 #include "auth/ntlm/Scheme.h"
@@ -200,7 +200,7 @@
 /* NTLM Scheme */
 
 void
-Auth::Ntlm::Config::fixHeader(AuthUserRequest::Pointer auth_user_request, HttpReply *rep, http_hdr_type hdrType, HttpRequest * request)
+Auth::Ntlm::Config::fixHeader(Auth::UserRequest::Pointer auth_user_request, HttpReply *rep, http_hdr_type hdrType, HttpRequest * request)
 {
     if (!authenticateProgram)
         return;
@@ -219,7 +219,7 @@
             request->flags.proxy_keepalive = 0;
         }
     } else {
-        AuthNTLMUserRequest *ntlm_request = dynamic_cast<AuthNTLMUserRequest *>(auth_user_request.getRaw());
+        Auth::Ntlm::UserRequest *ntlm_request = dynamic_cast<Auth::Ntlm::UserRequest *>(auth_user_request.getRaw());
         assert(ntlm_request != NULL);
 
         switch (ntlm_request->user()->credentials()) {
@@ -267,11 +267,11 @@
  * Decode a NTLM [Proxy-]Auth string, placing the results in the passed
  * Auth_user structure.
  */
-AuthUserRequest::Pointer
+Auth::UserRequest::Pointer
 Auth::Ntlm::Config::decode(char const *proxy_auth)
 {
     Auth::Ntlm::User *newUser = new Auth::Ntlm::User(Auth::Config::Find("ntlm"));
-    AuthUserRequest::Pointer auth_user_request = new AuthNTLMUserRequest();
+    Auth::UserRequest::Pointer auth_user_request = new Auth::Ntlm::UserRequest();
     assert(auth_user_request->user() == NULL);
 
     auth_user_request->user(newUser);
diff -u -r -N squid-3.2.0.14/src/auth/ntlm/auth_ntlm.h squid-3.2.0.15/src/auth/ntlm/auth_ntlm.h
--- squid-3.2.0.14/src/auth/ntlm/auth_ntlm.h	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/auth/ntlm/auth_ntlm.h	2012-02-06 04:52:31.000000000 +1300
@@ -27,11 +27,11 @@
     Config();
     virtual bool active() const;
     virtual bool configured() const;
-    virtual AuthUserRequest::Pointer decode(char const *proxy_auth);
+    virtual Auth::UserRequest::Pointer decode(char const *proxy_auth);
     virtual void done();
     virtual void rotateHelpers();
     virtual void dump(StoreEntry *, const char *, Auth::Config *);
-    virtual void fixHeader(AuthUserRequest::Pointer, HttpReply *, http_hdr_type, HttpRequest *);
+    virtual void fixHeader(Auth::UserRequest::Pointer, HttpReply *, http_hdr_type, HttpRequest *);
     virtual void init(Auth::Config *);
     virtual void parse(Auth::Config *, int, char *);
     virtual void registerWithCacheManager(void);
diff -u -r -N squid-3.2.0.14/src/auth/ntlm/Scheme.cc squid-3.2.0.15/src/auth/ntlm/Scheme.cc
--- squid-3.2.0.14/src/auth/ntlm/Scheme.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/auth/ntlm/Scheme.cc	2012-02-06 04:52:31.000000000 +1300
@@ -30,7 +30,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 #include "auth/ntlm/auth_ntlm.h"
 #include "auth/ntlm/Scheme.h"
 #include "helper.h"
diff -u -r -N squid-3.2.0.14/src/auth/ntlm/User.cc squid-3.2.0.15/src/auth/ntlm/User.cc
--- squid-3.2.0.14/src/auth/ntlm/User.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/auth/ntlm/User.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "config.h"
+#include "squid.h"
 #include "auth/Config.h"
 #include "auth/ntlm/User.h"
 #include "Debug.h"
diff -u -r -N squid-3.2.0.14/src/auth/ntlm/UserRequest.cc squid-3.2.0.15/src/auth/ntlm/UserRequest.cc
--- squid-3.2.0.14/src/auth/ntlm/UserRequest.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/auth/ntlm/UserRequest.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "config.h"
+#include "squid.h"
 #include "auth/ntlm/auth_ntlm.h"
 #include "auth/ntlm/UserRequest.h"
 #include "auth/State.h"
@@ -6,7 +6,7 @@
 #include "HttpRequest.h"
 #include "SquidTime.h"
 
-AuthNTLMUserRequest::AuthNTLMUserRequest()
+Auth::Ntlm::UserRequest::UserRequest()
 {
     waiting=0;
     client_blob=0;
@@ -15,7 +15,7 @@
     request=NULL;
 }
 
-AuthNTLMUserRequest::~AuthNTLMUserRequest()
+Auth::Ntlm::UserRequest::~UserRequest()
 {
     assert(RefCountCount()==0);
     safe_free(server_blob);
@@ -30,13 +30,13 @@
 }
 
 const char *
-AuthNTLMUserRequest::connLastHeader()
+Auth::Ntlm::UserRequest::connLastHeader()
 {
     return NULL;
 }
 
 int
-AuthNTLMUserRequest::authenticated() const
+Auth::Ntlm::UserRequest::authenticated() const
 {
     if (user() != NULL && user()->credentials() == Auth::Ok) {
         debugs(29, 9, HERE << "user authenticated.");
@@ -48,9 +48,9 @@
 }
 
 Auth::Direction
-AuthNTLMUserRequest::module_direction()
+Auth::Ntlm::UserRequest::module_direction()
 {
-    /* null auth_user is checked for by AuthUserRequest::direction() */
+    /* null auth_user is checked for by Auth::UserRequest::direction() */
 
     if (waiting || client_blob)
         return Auth::CRED_LOOKUP; /* need helper response to continue */
@@ -77,7 +77,7 @@
 }
 
 void
-AuthNTLMUserRequest::module_start(RH * handler, void *data)
+Auth::Ntlm::UserRequest::module_start(RH * handler, void *data)
 {
     static char buf[MAX_AUTHTOKEN_LEN];
 
@@ -101,7 +101,7 @@
     waiting = 1;
 
     safe_free(client_blob);
-    helperStatefulSubmit(ntlmauthenticators, buf, AuthNTLMUserRequest::HandleReply,
+    helperStatefulSubmit(ntlmauthenticators, buf, Auth::Ntlm::UserRequest::HandleReply,
                          new Auth::StateData(this, handler, data), authserver);
 }
 
@@ -110,7 +110,7 @@
  * for this request connections use.
  */
 void
-AuthNTLMUserRequest::releaseAuthServer()
+Auth::Ntlm::UserRequest::releaseAuthServer()
 {
     if (authserver) {
         debugs(29, 6, HERE << "releasing NTLM auth server '" << authserver << "'");
@@ -121,14 +121,14 @@
 }
 
 void
-AuthNTLMUserRequest::onConnectionClose(ConnStateData *conn)
+Auth::Ntlm::UserRequest::onConnectionClose(ConnStateData *conn)
 {
     assert(conn != NULL);
 
-    debugs(29, 8, "AuthNTLMUserRequest::onConnectionClose: closing connection '" << conn << "' (this is '" << this << "')");
+    debugs(29, 8, HERE << "closing connection '" << conn << "' (this is '" << this << "')");
 
     if (conn->auth_user_request == NULL) {
-        debugs(29, 8, "AuthNTLMUserRequest::onConnectionClose: no auth_user_request");
+        debugs(29, 8, HERE << "no auth_user_request");
         return;
     }
 
@@ -141,7 +141,7 @@
 }
 
 void
-AuthNTLMUserRequest::authenticate(HttpRequest * aRequest, ConnStateData * conn, http_hdr_type type)
+Auth::Ntlm::UserRequest::authenticate(HttpRequest * aRequest, ConnStateData * conn, http_hdr_type type)
 {
     assert(this);
 
@@ -212,7 +212,7 @@
         break;
 
     case Auth::Ok:
-        fatal("AuthNTLMUserRequest::authenticate: unexpect auth state DONE! Report a bug to the squid developers.\n");
+        fatal("Auth::Ntlm::UserRequest::authenticate: unexpect auth state DONE! Report a bug to the squid developers.\n");
         break;
 
     case Auth::Failed:
@@ -223,7 +223,7 @@
 }
 
 void
-AuthNTLMUserRequest::HandleReply(void *data, void *lastserver, char *reply)
+Auth::Ntlm::UserRequest::HandleReply(void *data, void *lastserver, char *reply)
 {
     Auth::StateData *r = static_cast<Auth::StateData *>(data);
     char *blob;
@@ -241,10 +241,10 @@
         reply = (char *)"BH Internal error";
     }
 
-    AuthUserRequest::Pointer auth_user_request = r->auth_user_request;
+    Auth::UserRequest::Pointer auth_user_request = r->auth_user_request;
     assert(auth_user_request != NULL);
 
-    AuthNTLMUserRequest *lm_request = dynamic_cast<AuthNTLMUserRequest *>(auth_user_request.getRaw());
+    Auth::Ntlm::UserRequest *lm_request = dynamic_cast<Auth::Ntlm::UserRequest *>(auth_user_request.getRaw());
     assert(lm_request != NULL);
     assert(lm_request->waiting);
 
diff -u -r -N squid-3.2.0.14/src/auth/ntlm/UserRequest.h squid-3.2.0.15/src/auth/ntlm/UserRequest.h
--- squid-3.2.0.14/src/auth/ntlm/UserRequest.h	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/auth/ntlm/UserRequest.h	2012-02-06 04:52:31.000000000 +1300
@@ -10,14 +10,19 @@
 class HttpRequest;
 class helper_stateful_server;
 
-class AuthNTLMUserRequest : public AuthUserRequest
+namespace Auth
+{
+namespace Ntlm
+{
+
+class UserRequest : public Auth::UserRequest
 {
 
 public:
-    MEMPROXY_CLASS(AuthNTLMUserRequest);
+    MEMPROXY_CLASS(Auth::Ntlm::UserRequest);
 
-    AuthNTLMUserRequest();
-    virtual ~AuthNTLMUserRequest();
+    UserRequest();
+    virtual ~UserRequest();
     virtual int authenticated() const;
     virtual void authenticate(HttpRequest * request, ConnStateData * conn, http_hdr_type type);
     virtual Auth::Direction module_direction();
@@ -30,9 +35,6 @@
     helper_stateful_server *authserver;
     void releaseAuthServer(void); ///< Release authserver NTLM helpers properly when finished or abandoning.
 
-    /* what connection is this associated with */
-//    ConnStateData * conn;
-
     /* our current blob to pass to the client */
     char *server_blob;
 
@@ -49,6 +51,9 @@
     static HLPSCB HandleReply;
 };
 
-MEMPROXY_CLASS_INLINE(AuthNTLMUserRequest);
+} // namespace Ntlm
+} // namespace Auth
+
+MEMPROXY_CLASS_INLINE(Auth::Ntlm::UserRequest);
 
 #endif /* _SQUID_SRC_AUTH_NTLM_USERREQUEST_H */
diff -u -r -N squid-3.2.0.14/src/auth/Scheme.cc squid-3.2.0.15/src/auth/Scheme.cc
--- squid-3.2.0.14/src/auth/Scheme.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/auth/Scheme.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
  * Copyright (c) 2004, Robert Collins <robertc@squid-cache.org>
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "auth/Scheme.h"
 #include "auth/Gadgets.h"
 #include "auth/Config.h"
diff -u -r -N squid-3.2.0.14/src/auth/State.cc squid-3.2.0.15/src/auth/State.cc
--- squid-3.2.0.14/src/auth/State.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/auth/State.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "config.h"
+#include "squid.h"
 
 #if USE_AUTH
 #include "auth/State.h"
diff -u -r -N squid-3.2.0.14/src/auth/State.h squid-3.2.0.15/src/auth/State.h
--- squid-3.2.0.14/src/auth/State.h	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/auth/State.h	2012-02-06 04:52:31.000000000 +1300
@@ -15,7 +15,7 @@
 class StateData
 {
 public:
-    StateData(const AuthUserRequest::Pointer &r, RH *h, void *d) :
+    StateData(const UserRequest::Pointer &r, RH *h, void *d) :
             data(cbdataReference(d)),
             auth_user_request(r),
             handler(h) {}
@@ -26,7 +26,7 @@
     }
 
     void *data;
-    AuthUserRequest::Pointer auth_user_request;
+    UserRequest::Pointer auth_user_request;
     RH *handler;
 
 private:
diff -u -r -N squid-3.2.0.14/src/auth/Type.cc squid-3.2.0.15/src/auth/Type.cc
--- squid-3.2.0.14/src/auth/Type.cc	2011-12-13 01:29:28.000000000 +1300
+++ squid-3.2.0.15/src/auth/Type.cc	2012-02-06 06:02:47.000000000 +1300
@@ -1,7 +1,7 @@
 /*
  * Auto-Generated File. Changes will be destroyed.
  */
-#include "config.h"
+#include "squid.h"
 #include "auth/Type.h"
 namespace Auth
 {
diff -u -r -N squid-3.2.0.14/src/auth/User.cc squid-3.2.0.15/src/auth/User.cc
--- squid-3.2.0.14/src/auth/User.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/auth/User.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
  * Copyright (c) 2003, Robert Collins <robertc@squid-cache.org>
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "auth/User.h"
 #include "auth/UserRequest.h"
 #include "auth/Config.h"
diff -u -r -N squid-3.2.0.14/src/auth/UserRequest.cc squid-3.2.0.15/src/auth/UserRequest.cc
--- squid-3.2.0.14/src/auth/UserRequest.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/auth/UserRequest.cc	2012-02-06 04:52:31.000000000 +1300
@@ -39,15 +39,11 @@
  * They DO NOT perform access control or auditing.
  * See acl.c for access control and client_side.c for auditing */
 
-#include "squid.h"
-#include "auth/UserRequest.h"
-#include "auth/User.h"
-/*#include "auth/Gadgets.h"
-#include "acl/Acl.h"
-#include "client_side.h"
-*/
+#include "squid-old.h"
 #include "auth/Config.h"
 #include "auth/Scheme.h"
+#include "auth/UserRequest.h"
+#include "auth/User.h"
 #include "comm/Connection.h"
 #include "HttpReply.h"
 #include "HttpRequest.h"
@@ -55,7 +51,7 @@
 /* Generic Functions */
 
 char const *
-AuthUserRequest::username() const
+Auth::UserRequest::username() const
 {
     if (user() != NULL)
         return user()->username();
@@ -67,18 +63,18 @@
 
 /* send the initial data to an authenticator module */
 void
-AuthUserRequest::start(RH * handler, void *data)
+Auth::UserRequest::start(RH * handler, void *data)
 {
     assert(handler);
     assert(data);
-    debugs(29, 9, "authenticateStart: auth_user_request '" << this << "'");
+    debugs(29, 9, HERE << "auth_user_request '" << this << "'");
     module_start(handler, data);
 }
 
 bool
-AuthUserRequest::valid() const
+Auth::UserRequest::valid() const
 {
-    debugs(29, 9, HERE << "Validating AuthUserRequest '" << this << "'.");
+    debugs(29, 9, HERE << "Validating Auth::UserRequest '" << this << "'.");
 
     if (user() == NULL) {
         debugs(29, 4, HERE << "No associated Auth::User data");
@@ -98,35 +94,35 @@
     /* any other sanity checks that we need in the future */
 
     /* finally return ok */
-    debugs(29, 5, HERE << "Validated. AuthUserRequest '" << this << "'.");
+    debugs(29, 5, HERE << "Validated. Auth::UserRequest '" << this << "'.");
     return true;
 }
 
 void *
-AuthUserRequest::operator new (size_t byteCount)
+Auth::UserRequest::operator new (size_t byteCount)
 {
-    fatal ("AuthUserRequest not directly allocatable\n");
+    fatal("Auth::UserRequest not directly allocatable\n");
     return (void *)1;
 }
 
 void
-AuthUserRequest::operator delete (void *address)
+Auth::UserRequest::operator delete (void *address)
 {
-    fatal ("AuthUserRequest child failed to override operator delete\n");
+    fatal("Auth::UserRequest child failed to override operator delete\n");
 }
 
-AuthUserRequest::AuthUserRequest():
+Auth::UserRequest::UserRequest():
         _auth_user(NULL),
         message(NULL),
         lastReply(AUTH_ACL_CANNOT_AUTHENTICATE)
 {
-    debugs(29, 5, "AuthUserRequest::AuthUserRequest: initialised request " << this);
+    debugs(29, 5, HERE << "initialised request " << this);
 }
 
-AuthUserRequest::~AuthUserRequest()
+Auth::UserRequest::~UserRequest()
 {
     assert(RefCountCount()==0);
-    debugs(29, 5, "AuthUserRequest::~AuthUserRequest: freeing request " << this);
+    debugs(29, 5, HERE << "freeing request " << this);
 
     if (user() != NULL) {
         /* release our references to the user credentials */
@@ -137,20 +133,20 @@
 }
 
 void
-AuthUserRequest::setDenyMessage(char const *aString)
+Auth::UserRequest::setDenyMessage(char const *aString)
 {
     safe_free(message);
     message = xstrdup(aString);
 }
 
 char const *
-AuthUserRequest::getDenyMessage()
+Auth::UserRequest::getDenyMessage()
 {
     return message;
 }
 
 char const *
-AuthUserRequest::denyMessage(char const * const default_message)
+Auth::UserRequest::denyMessage(char const * const default_message)
 {
     if (this == NULL || getDenyMessage() == NULL) {
         return default_message;
@@ -160,7 +156,7 @@
 }
 
 static void
-authenticateAuthUserRequestSetIp(AuthUserRequest::Pointer auth_user_request, Ip::Address &ipaddr)
+authenticateAuthUserRequestSetIp(Auth::UserRequest::Pointer auth_user_request, Ip::Address &ipaddr)
 {
     Auth::User::Pointer auth_user = auth_user_request->user();
 
@@ -171,7 +167,7 @@
 }
 
 void
-authenticateAuthUserRequestRemoveIp(AuthUserRequest::Pointer auth_user_request, Ip::Address const &ipaddr)
+authenticateAuthUserRequestRemoveIp(Auth::UserRequest::Pointer auth_user_request, Ip::Address const &ipaddr)
 {
     Auth::User::Pointer auth_user = auth_user_request->user();
 
@@ -182,14 +178,14 @@
 }
 
 void
-authenticateAuthUserRequestClearIp(AuthUserRequest::Pointer auth_user_request)
+authenticateAuthUserRequestClearIp(Auth::UserRequest::Pointer auth_user_request)
 {
     if (auth_user_request != NULL)
         auth_user_request->user()->clearIp();
 }
 
 int
-authenticateAuthUserRequestIPCount(AuthUserRequest::Pointer auth_user_request)
+authenticateAuthUserRequestIPCount(Auth::UserRequest::Pointer auth_user_request)
 {
     assert(auth_user_request != NULL);
     assert(auth_user_request->user() != NULL);
@@ -201,7 +197,7 @@
  * authenticateUserAuthenticated: is this auth_user structure logged in ?
  */
 int
-authenticateUserAuthenticated(AuthUserRequest::Pointer auth_user_request)
+authenticateUserAuthenticated(Auth::UserRequest::Pointer auth_user_request)
 {
     if (auth_user_request == NULL || !auth_user_request->valid())
         return 0;
@@ -210,7 +206,7 @@
 }
 
 Auth::Direction
-AuthUserRequest::direction()
+Auth::UserRequest::direction()
 {
     if (user() == NULL)
         return Auth::CRED_ERROR; // No credentials. Should this be a CHALLENGE instead?
@@ -222,21 +218,21 @@
 }
 
 void
-AuthUserRequest::addAuthenticationInfoHeader(HttpReply * rep, int accelerated)
+Auth::UserRequest::addAuthenticationInfoHeader(HttpReply * rep, int accelerated)
 {}
 
 void
-AuthUserRequest::addAuthenticationInfoTrailer(HttpReply * rep, int accelerated)
+Auth::UserRequest::addAuthenticationInfoTrailer(HttpReply * rep, int accelerated)
 {}
 
 void
-AuthUserRequest::onConnectionClose(ConnStateData *)
+Auth::UserRequest::onConnectionClose(ConnStateData *)
 {}
 
 const char *
-AuthUserRequest::connLastHeader()
+Auth::UserRequest::connLastHeader()
 {
-    fatal("AuthUserRequest::connLastHeader should always be overridden by conn based auth schemes");
+    fatal("Auth::UserRequest::connLastHeader should always be overridden by conn based auth schemes");
     return NULL;
 }
 
@@ -247,15 +243,15 @@
  * This is basically a handle approach.
  */
 static void
-authenticateAuthenticateUser(AuthUserRequest::Pointer auth_user_request, HttpRequest * request, ConnStateData * conn, http_hdr_type type)
+authenticateAuthenticateUser(Auth::UserRequest::Pointer auth_user_request, HttpRequest * request, ConnStateData * conn, http_hdr_type type)
 {
     assert(auth_user_request.getRaw() != NULL);
 
     auth_user_request->authenticate(request, conn, type);
 }
 
-static AuthUserRequest::Pointer
-authTryGetUser(AuthUserRequest::Pointer auth_user_request, ConnStateData * conn, HttpRequest * request)
+static Auth::UserRequest::Pointer
+authTryGetUser(Auth::UserRequest::Pointer auth_user_request, ConnStateData * conn, HttpRequest * request)
 {
     if (auth_user_request != NULL)
         return auth_user_request;
@@ -289,7 +285,7 @@
  * Caller is responsible for locking and unlocking their *auth_user_request!
  */
 AuthAclState
-AuthUserRequest::authenticate(AuthUserRequest::Pointer * auth_user_request, http_hdr_type headertype, HttpRequest * request, ConnStateData * conn, Ip::Address &src_addr)
+Auth::UserRequest::authenticate(Auth::UserRequest::Pointer * auth_user_request, http_hdr_type headertype, HttpRequest * request, ConnStateData * conn, Ip::Address &src_addr)
 {
     const char *proxy_auth;
     assert(headertype != 0);
@@ -355,7 +351,7 @@
             Auth::Config * scheme = Auth::Config::Find(proxy_auth);
 
             if (conn->auth_user_request->user() == NULL || conn->auth_user_request->user()->config != scheme) {
-                debugs(29, 1, "WARNING: Unexpected change of authentication scheme from '" <<
+                debugs(29, DBG_IMPORTANT, "WARNING: Unexpected change of authentication scheme from '" <<
                        conn->auth_user_request->user()->config->type() <<
                        "' to '" << proxy_auth << "' (client " <<
                        src_addr << ")");
@@ -455,14 +451,14 @@
 }
 
 AuthAclState
-AuthUserRequest::tryToAuthenticateAndSetAuthUser(AuthUserRequest::Pointer * auth_user_request, http_hdr_type headertype, HttpRequest * request, ConnStateData * conn, Ip::Address &src_addr)
+Auth::UserRequest::tryToAuthenticateAndSetAuthUser(Auth::UserRequest::Pointer * aUR, http_hdr_type headertype, HttpRequest * request, ConnStateData * conn, Ip::Address &src_addr)
 {
-    /* If we have already been called, return the cached value */
-    AuthUserRequest::Pointer t = authTryGetUser(*auth_user_request, conn, request);
+    // If we have already been called, return the cached value
+    Auth::UserRequest::Pointer t = authTryGetUser(*aUR, conn, request);
 
     if (t != NULL && t->lastReply != AUTH_ACL_CANNOT_AUTHENTICATE && t->lastReply != AUTH_ACL_HELPER) {
-        if (*auth_user_request == NULL)
-            *auth_user_request = t;
+        if (*aUR == NULL)
+            *aUR = t;
 
         if (request->auth_user_request == NULL && t->lastReply == AUTH_AUTHENTICATED) {
             request->auth_user_request = t;
@@ -470,10 +466,11 @@
         return t->lastReply;
     }
 
-    /* ok, call the actual authenticator routine. */
-    AuthAclState result = authenticate(auth_user_request, headertype, request, conn, src_addr);
+    // ok, call the actual authenticator routine.
+    AuthAclState result = authenticate(aUR, headertype, request, conn, src_addr);
 
-    t = authTryGetUser(*auth_user_request, conn, request);
+    // auth process may have changed the UserRequest we are dealing with
+    t = authTryGetUser(*aUR, conn, request);
 
     if (t != NULL && result != AUTH_ACL_CANNOT_AUTHENTICATE && result != AUTH_ACL_HELPER)
         t->lastReply = result;
@@ -482,7 +479,7 @@
 }
 
 void
-AuthUserRequest::addReplyAuthHeader(HttpReply * rep, AuthUserRequest::Pointer auth_user_request, HttpRequest * request, int accelerated, int internal)
+Auth::UserRequest::addReplyAuthHeader(HttpReply * rep, Auth::UserRequest::Pointer auth_user_request, HttpRequest * request, int accelerated, int internal)
 /* send the auth types we are configured to support (and have compiled in!) */
 {
     http_hdr_type type;
@@ -506,7 +503,7 @@
         break;
     }
 
-    debugs(29, 9, "authenticateFixHeader: headertype:" << type << " authuser:" << auth_user_request);
+    debugs(29, 9, HERE << "headertype:" << type << " authuser:" << auth_user_request);
 
     if (((rep->sline.status == HTTP_PROXY_AUTHENTICATION_REQUIRED)
             || (rep->sline.status == HTTP_UNAUTHORIZED)) && internal)
@@ -525,7 +522,7 @@
                 if (scheme->active())
                     scheme->fixHeader(NULL, rep, type, request);
                 else
-                    debugs(29, 4, "authenticateFixHeader: Configured scheme " << scheme->type() << " not Active");
+                    debugs(29, 4, HERE << "Configured scheme " << scheme->type() << " not Active");
             }
         }
 
@@ -542,22 +539,24 @@
     }
 }
 
+// TODO remove wrapper.
 void
-authenticateFixHeader(HttpReply * rep, AuthUserRequest::Pointer auth_user_request, HttpRequest * request, int accelerated, int internal)
+authenticateFixHeader(HttpReply * rep, Auth::UserRequest::Pointer auth_user_request, HttpRequest * request, int accelerated, int internal)
 {
-    AuthUserRequest::addReplyAuthHeader(rep, auth_user_request, request, accelerated, internal);
+    Auth::UserRequest::addReplyAuthHeader(rep, auth_user_request, request, accelerated, internal);
 }
 
 /* call the active auth module and allow it to add a trailer to the request */
+// TODO remove wrapper
 void
-authenticateAddTrailer(HttpReply * rep, AuthUserRequest::Pointer auth_user_request, HttpRequest * request, int accelerated)
+authenticateAddTrailer(HttpReply * rep, Auth::UserRequest::Pointer auth_user_request, HttpRequest * request, int accelerated)
 {
     if (auth_user_request != NULL)
         auth_user_request->addAuthenticationInfoTrailer(rep, accelerated);
 }
 
 Auth::Scheme::Pointer
-AuthUserRequest::scheme() const
+Auth::UserRequest::scheme() const
 {
     return Auth::Scheme::Find(user()->config->type());
 }
diff -u -r -N squid-3.2.0.14/src/auth/UserRequest.h squid-3.2.0.15/src/auth/UserRequest.h
--- squid-3.2.0.14/src/auth/UserRequest.h	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/auth/UserRequest.h	2012-02-06 04:52:31.000000000 +1300
@@ -32,8 +32,8 @@
  *
  */
 
-#ifndef SQUID_AUTHUSERREQUEST_H
-#define SQUID_AUTHUSERREQUEST_H
+#ifndef SQUID_AUTH_USERREQUEST_H
+#define SQUID_AUTH_USERREQUEST_H
 
 #if USE_AUTH
 
@@ -77,19 +77,22 @@
     CRED_LOOKUP = -1,   ///< Credentials need to be validated with the backend helper
     CRED_ERROR = -2     ///< ERROR in the auth module. Cannot determine the state of this request.
 };
-} // namespace Auth
 
 /**
- \ingroup AuthAPI
  * This is a short lived structure is the visible aspect of the authentication framework.
  *
  * It and its children hold the state data while processing authentication for a client request.
  * The AuthenticationStateData object is merely a CBDATA wrapper for one of these.
  */
-class AuthUserRequest : public RefCountable
+class UserRequest : public RefCountable
 {
 public:
-    typedef RefCount<AuthUserRequest> Pointer;
+    typedef RefCount<Auth::UserRequest> Pointer;
+
+    UserRequest();
+    virtual ~UserRequest();
+    void *operator new(size_t byteCount);
+    void operator delete(void *address);
 
 public:
     /**
@@ -97,7 +100,7 @@
      * it has request specific data, and links to user specific data
      * the user
      */
-    Auth::User::Pointer _auth_user;
+    User::Pointer _auth_user;
 
     /**
      *  Used by squid to determine what the next step in performing authentication for a given scheme is.
@@ -111,7 +114,7 @@
      *				Squid will return the appropriate status code (401 or 407) and call the registered
      *				FixError function to allow the auth module to insert it's challenge.
      */
-    Auth::Direction direction();
+    Direction direction();
 
     /**
      * Used by squid to determine whether the auth scheme has successfully authenticated the user request.
@@ -136,7 +139,7 @@
     virtual void authenticate(HttpRequest * request, ConnStateData * conn, http_hdr_type type) = 0;
 
     /* template method - what needs to be done next? advertise schemes, challenge, handle error, nothing? */
-    virtual Auth::Direction module_direction() = 0;
+    virtual Direction module_direction() = 0;
 
     /* add the [Proxy-]Authentication-Info header */
     virtual void addAuthenticationInfoHeader(HttpReply * rep, int accel);
@@ -155,20 +158,33 @@
      */
     virtual void module_start(RH *handler, void *data) = 0;
 
-    virtual Auth::User::Pointer user() {return _auth_user;}
+    // User credentials object this UserRequest is managing
+    virtual User::Pointer user() {return _auth_user;}
+    virtual const User::Pointer user() const {return _auth_user;}
+    virtual void user(User::Pointer aUser) {_auth_user=aUser;}
 
-    virtual const Auth::User::Pointer user() const {return _auth_user;}
-
-    virtual void user(Auth::User::Pointer aUser) {_auth_user=aUser;}
-
-    static AuthAclState tryToAuthenticateAndSetAuthUser(AuthUserRequest::Pointer *, http_hdr_type, HttpRequest *, ConnStateData *, Ip::Address &);
-    static void addReplyAuthHeader(HttpReply * rep, AuthUserRequest::Pointer auth_user_request, HttpRequest * request, int accelerated, int internal);
-
-    AuthUserRequest();
+    /**
+     * Locate user credentials in one of several locations. Begin authentication if needed.
+     *
+     * Credentials may be found in one of the following locations (listed by order of preference):
+     * - the source passed as parameter aUR
+     * - cached in the HttpRequest parameter from a previous authentication of this request
+     * - cached in the ConnStateData paremeter from a previous authentication of this connection
+     *   (only applies to some situations. ie NTLM, Negotiate, Kerberos auth schemes,
+     *    or decrypted SSL requests from inside an authenticated CONNECT tunnel)
+     * - cached in the user credentials cache from a previous authentication of the same credentials
+     *   (only applies to cacheable authentication methods, ie Basic auth)
+     * - new credentials created from HTTP headers in this request
+     *
+     * The found credentials are returned in aUR and if successfully authenticated
+     * may now be cached in one or more of the above locations.
+     *
+     * \return Some AUTH_ACL_* state
+     */
+    static AuthAclState tryToAuthenticateAndSetAuthUser(UserRequest::Pointer *aUR, http_hdr_type, HttpRequest *, ConnStateData *, Ip::Address &);
 
-    virtual ~AuthUserRequest();
-    void *operator new(size_t byteCount);
-    void operator delete(void *address);
+    /// Add the appropriate [Proxy-]Authenticate header to the given reply
+    static void addReplyAuthHeader(HttpReply * rep, UserRequest::Pointer auth_user_request, HttpRequest * request, int accelerated, int internal);
 
     void start( RH * handler, void *data);
     char const * denyMessage(char const * const default_message = NULL);
@@ -189,13 +205,13 @@
      */
     char const *username() const;
 
-    Auth::Scheme::Pointer scheme() const;
+    Scheme::Pointer scheme() const;
 
     virtual const char * connLastHeader();
 
 private:
 
-    static AuthAclState authenticate(AuthUserRequest::Pointer * auth_user_request, http_hdr_type headertype, HttpRequest * request, ConnStateData * conn, Ip::Address &src_addr);
+    static AuthAclState authenticate(UserRequest::Pointer * auth_user_request, http_hdr_type headertype, HttpRequest * request, ConnStateData * conn, Ip::Address &src_addr);
 
     /** return a message on the 407 error pages */
     char *message;
@@ -208,23 +224,25 @@
     AuthAclState lastReply;
 };
 
+} // namespace Auth
+
 /* AuthUserRequest */
 
 /// \ingroup AuthAPI
-extern void authenticateFixHeader(HttpReply *, AuthUserRequest::Pointer, HttpRequest *, int, int);
+extern void authenticateFixHeader(HttpReply *, Auth::UserRequest::Pointer, HttpRequest *, int, int);
 /// \ingroup AuthAPI
-extern void authenticateAddTrailer(HttpReply *, AuthUserRequest::Pointer, HttpRequest *, int);
+extern void authenticateAddTrailer(HttpReply *, Auth::UserRequest::Pointer, HttpRequest *, int);
 
 /// \ingroup AuthAPI
-extern void authenticateAuthUserRequestRemoveIp(AuthUserRequest::Pointer, Ip::Address const &);
+extern void authenticateAuthUserRequestRemoveIp(Auth::UserRequest::Pointer, Ip::Address const &);
 /// \ingroup AuthAPI
-extern void authenticateAuthUserRequestClearIp(AuthUserRequest::Pointer);
+extern void authenticateAuthUserRequestClearIp(Auth::UserRequest::Pointer);
 /// \ingroup AuthAPI
-extern int authenticateAuthUserRequestIPCount(AuthUserRequest::Pointer);
+extern int authenticateAuthUserRequestIPCount(Auth::UserRequest::Pointer);
 
 /// \ingroup AuthAPI
-/// See AuthUserRequest::authenticated()
-extern int authenticateUserAuthenticated(AuthUserRequest::Pointer);
+/// See Auth::UserRequest::authenticated()
+extern int authenticateUserAuthenticated(Auth::UserRequest::Pointer);
 
 #endif /* USE_AUTH */
 #endif /* SQUID_AUTHUSERREQUEST_H */
diff -u -r -N squid-3.2.0.14/src/AuthReg.cc squid-3.2.0.15/src/AuthReg.cc
--- squid-3.2.0.14/src/AuthReg.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/AuthReg.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "config.h"
+#include "squid.h"
 
 #if USE_AUTH
 
diff -u -r -N squid-3.2.0.14/src/base/AsyncCall.cc squid-3.2.0.15/src/base/AsyncCall.cc
--- squid-3.2.0.14/src/base/AsyncCall.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/base/AsyncCall.cc	2012-02-06 04:52:31.000000000 +1300
@@ -2,7 +2,7 @@
  * $Id$
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "base/AsyncCall.h"
 #include "base/AsyncCallQueue.h"
 #include "cbdata.h"
diff -u -r -N squid-3.2.0.14/src/base/AsyncCallQueue.cc squid-3.2.0.15/src/base/AsyncCallQueue.cc
--- squid-3.2.0.14/src/base/AsyncCallQueue.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/base/AsyncCallQueue.cc	2012-02-06 04:52:31.000000000 +1300
@@ -6,7 +6,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 #include "base/AsyncCallQueue.h"
 #include "base/AsyncCall.h"
 
diff -u -r -N squid-3.2.0.14/src/base/AsyncCallQueue.h squid-3.2.0.15/src/base/AsyncCallQueue.h
--- squid-3.2.0.14/src/base/AsyncCallQueue.h	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/base/AsyncCallQueue.h	2012-02-06 04:52:31.000000000 +1300
@@ -7,7 +7,7 @@
 #ifndef SQUID_ASYNCCALLQUEUE_H
 #define SQUID_ASYNCCALLQUEUE_H
 
-#include "squid.h"
+#include "squid-old.h"
 #include "base/AsyncCall.h"
 
 //class AsyncCall;
diff -u -r -N squid-3.2.0.14/src/base/AsyncJob.cc squid-3.2.0.15/src/base/AsyncJob.cc
--- squid-3.2.0.14/src/base/AsyncJob.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/base/AsyncJob.cc	2012-02-06 04:52:31.000000000 +1300
@@ -2,7 +2,7 @@
  * DEBUG: section 93    ICAP (RFC 3507) Client
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "base/AsyncCall.h"
 #include "base/AsyncJob.h"
 #include "base/AsyncJobCalls.h"
diff -u -r -N squid-3.2.0.14/src/base/RunnersRegistry.cc squid-3.2.0.15/src/base/RunnersRegistry.cc
--- squid-3.2.0.14/src/base/RunnersRegistry.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/base/RunnersRegistry.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "config.h"
+#include "squid.h"
 #include "base/RunnersRegistry.h"
 #include <list>
 #include <map>
diff -u -r -N squid-3.2.0.14/src/base/RunnersRegistry.h squid-3.2.0.15/src/base/RunnersRegistry.h
--- squid-3.2.0.14/src/base/RunnersRegistry.h	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/base/RunnersRegistry.h	2012-02-06 04:52:31.000000000 +1300
@@ -21,13 +21,20 @@
 
 /// well-known registries
 typedef enum {
-    /// managed by main.cc; activated after parsing squid.conf but
-    /// before rrAfterConfig, deactivated after rrAfterConfig but
-    /// before freeing configuration-related memory or exit()-ing
+    /// Managed by main.cc. Activated after parsing squid.conf and
+    /// deactivated before freeing configuration-related memory or exit()-ing.
+    /// Meant for setting configuration options that depend on other
+    /// configuration options and were not explicitly configured.
+    rrFinalizeConfig,
+
+    /// Managed by main.cc. Activated after rrFinalizeConfig and
+    /// deactivated before rrFinalizeConfig. Meant for announcing
+    /// memory reservations before memory is allocated.
     rrClaimMemoryNeeds,
 
-    /// managed by main.cc; activated after parsing squid.conf and
-    /// deactivated before freeing configuration-related memory or exit()-ing
+    /// Managed by main.cc. Activated after rrClaimMemoryNeeds and
+    /// deactivated before rrClaimMemoryNeeds. Meant for activating
+    /// modules and features based on the finalized configuration.
     rrAfterConfig,
 
     rrEnd ///< not a real registry, just a label to mark the end of enum
diff -u -r -N squid-3.2.0.14/src/base/TextException.cc squid-3.2.0.15/src/base/TextException.cc
--- squid-3.2.0.14/src/base/TextException.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/base/TextException.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "squid.h"
+#include "squid-old.h"
 #include "base/TextException.h"
 #include "Debug.h"
 #include "util.h"
diff -u -r -N squid-3.2.0.14/src/BodyPipe.cc squid-3.2.0.15/src/BodyPipe.cc
--- squid-3.2.0.14/src/BodyPipe.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/BodyPipe.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,5 +1,5 @@
 
-#include "squid.h"
+#include "squid-old.h"
 #include "base/AsyncJobCalls.h"
 #include "base/TextException.h"
 #include "BodyPipe.h"
diff -u -r -N squid-3.2.0.14/src/cache_cf.cc squid-3.2.0.15/src/cache_cf.cc
--- squid-3.2.0.14/src/cache_cf.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/cache_cf.cc	2012-02-06 04:52:31.000000000 +1300
@@ -32,7 +32,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 
 #include "acl/Acl.h"
 #include "acl/Gadgets.h"
@@ -161,7 +161,7 @@
 #if USE_SSL
 static void parseBytesOptionValue(size_t * bptr, const char *units, char const * value);
 #endif
-#if !USE_DNSSERVERS
+#if !USE_DNSHELPER
 static void parseBytesLineSigned(ssize_t * bptr, const char *units);
 #endif
 static size_t parseBytesUnits(const char *unit);
@@ -189,17 +189,16 @@
 #endif /* CURRENTLY_UNUSED */
 #endif /* USE_WCCPv2 */
 
-static void parse_http_port_list(http_port_list **);
+static void parsePortList(http_port_list **, const char *protocol);
+#define parse_http_port_list(l) parsePortList((l),"http")
 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 void free_https_port_list(https_port_list **);
-#if 0
-static int check_null_https_port_list(const https_port_list *);
-#endif
+#define parse_https_port_list(l) parsePortList((l),"https")
+#define dump_https_port_list(e,n,l) dump_http_port_list((e),(n),(l))
+#define free_https_port_list(l) free_http_port_list((l))
+#define check_null_https_port_list(l) check_null_http_port_list((l))
 #endif /* USE_SSL */
 
 static void parse_b_size_t(size_t * var);
@@ -640,11 +639,9 @@
     else
         visible_appname_string = (char const *)APP_FULLNAME;
 
-#if USE_DNSSERVERS
-
+#if USE_DNSHELPER
     if (Config.dnsChildren.n_max < 1)
-        fatal("No dnsservers allocated");
-
+        fatal("No DNS helpers allocated");
 #endif
 
     if (Config.Program.redirect) {
@@ -705,8 +702,7 @@
     }
 
     requirePathnameExists("MIME Config Table", Config.mimeTablePathname);
-#if USE_DNSSERVERS
-
+#if USE_DNSHELPER
     requirePathnameExists("cache_dns_program", Config.Program.dnsserver);
 #endif
 #if USE_UNLINKD
@@ -904,7 +900,7 @@
             if (!s->cert && !s->key)
                 continue;
 
-            debugs(3, 1, "Initializing http_port " << s->http.s << " SSL context");
+            debugs(3, 1, "Initializing http_port " << s->s << " SSL context");
 
             s->staticSslContext.reset(
                 sslCreateServerContext(s->cert, s->key,
@@ -918,10 +914,10 @@
 
     {
 
-        https_port_list *s;
+        http_port_list *s;
 
-        for (s = Config.Sockaddr.https; s != NULL; s = (https_port_list *) s->http.next) {
-            debugs(3, 1, "Initializing https_port " << s->http.s << " SSL context");
+        for (s = Config.Sockaddr.https; s != NULL; s = s->next) {
+            debugs(3, 1, "Initializing https_port " << s->s << " SSL context");
 
             s->staticSslContext.reset(
                 sslCreateServerContext(s->cert, s->key,
@@ -1137,7 +1133,7 @@
         self_destruct();
 }
 
-#if !USE_DNSSERVERS
+#if !USE_DNSHELPER
 static void
 parseBytesLineSigned(ssize_t * bptr, const char *units)
 {
@@ -3056,7 +3052,7 @@
     *var = 0;
 }
 
-#if !USE_DNSSERVERS
+#if !USE_DNSHELPER
 static void
 dump_time_msec(StoreEntry * entry, const char *name, time_msec_t var)
 {
@@ -3093,7 +3089,7 @@
     storeAppendPrintf(entry, "%s %d %s\n", name, (int) var, B_BYTES_STR);
 }
 
-#if !USE_DNSSERVERS
+#if !USE_DNSHELPER
 static void
 dump_b_ssize_t(StoreEntry * entry, const char *name, ssize_t var)
 {
@@ -3137,7 +3133,7 @@
     parseBytesLine(var, B_BYTES_STR);
 }
 
-#if !USE_DNSSERVERS
+#if !USE_DNSHELPER
 static void
 parse_b_ssize_t(ssize_t * var)
 {
@@ -3171,7 +3167,7 @@
     *var = 0;
 }
 
-#if !USE_DNSSERVERS
+#if !USE_DNSHELPER
 static void
 free_ssize_t(ssize_t * var)
 {
@@ -3518,7 +3514,7 @@
 CBDATA_CLASS_INIT(http_port_list);
 
 static void
-parse_http_port_specification(http_port_list * s, char *token)
+parsePortSpecification(http_port_list * s, char *token)
 {
     char *host = NULL;
     unsigned short port = 0;
@@ -3534,16 +3530,16 @@
         host = token + 1;
         t = strchr(host, ']');
         if (!t) {
-            debugs(3, 0, "http(s)_port: missing ']' on IPv6 address: " << token);
+            debugs(3, DBG_CRITICAL, s->protocol << "_port: missing ']' on IPv6 address: " << token);
             self_destruct();
         }
         *t++ = '\0';
         if (*t != ':') {
-            debugs(3, 0, "http(s)_port: missing Port in: " << token);
+            debugs(3, DBG_CRITICAL, s->protocol << "_port: missing Port in: " << token);
             self_destruct();
         }
         if (!Ip::EnableIpv6) {
-            debugs(3, DBG_CRITICAL, "FATAL: http(s)_port: IPv6 is not available.");
+            debugs(3, DBG_CRITICAL, "FATAL: " << s->protocol << "_port: IPv6 is not available.");
             self_destruct();
         }
         port = xatos(t + 1);
@@ -3556,14 +3552,14 @@
 
     } else if ((port = strtol(token, &junk, 10)), !*junk) {
         /* port */
-        debugs(3, 3, "http(s)_port: found Listen on Port: " << port);
+        debugs(3, 3, s->protocol << "_port: found Listen on Port: " << port);
     } else {
-        debugs(3, 0, "http(s)_port: missing Port: " << token);
+        debugs(3, DBG_CRITICAL, s->protocol << "_port: missing Port: " << token);
         self_destruct();
     }
 
-    if (port == 0) {
-        debugs(3, 0, "http(s)_port: Port cannot be 0: " << token);
+    if (port == 0 && host != NULL) {
+        debugs(3, DBG_CRITICAL, s->protocol << "_port: Port cannot be 0: " << token);
         self_destruct();
     }
 
@@ -3572,21 +3568,21 @@
         s->s.SetPort(port);
         if (!Ip::EnableIpv6)
             s->s.SetIPv4();
-        debugs(3, 3, "http(s)_port: found Listen on wildcard address: *:" << s->s.GetPort() );
+        debugs(3, 3, s->protocol << "_port: found Listen on wildcard address: *:" << s->s.GetPort() );
     } else if ( (s->s = host) ) { /* check/parse numeric IPA */
         s->s.SetPort(port);
         if (!Ip::EnableIpv6)
             s->s.SetIPv4();
-        debugs(3, 3, "http(s)_port: Listen on Host/IP: " << host << " --> " << s->s);
+        debugs(3, 3, s->protocol << "_port: Listen on Host/IP: " << host << " --> " << s->s);
     } else if ( s->s.GetHostByName(host) ) { /* check/parse for FQDN */
         /* dont use ipcache */
         s->defaultsite = xstrdup(host);
         s->s.SetPort(port);
         if (!Ip::EnableIpv6)
             s->s.SetIPv4();
-        debugs(3, 3, "http(s)_port: found Listen as Host " << s->defaultsite << " on IP: " << s->s);
+        debugs(3, 3, s->protocol << "_port: found Listen as Host " << s->defaultsite << " on IP: " << s->s);
     } else {
-        debugs(3, 0, "http(s)_port: failed to resolve Host/IP: " << host);
+        debugs(3, DBG_CRITICAL, s->protocol << "_port: failed to resolve Host/IP: " << host);
         self_destruct();
     }
 }
@@ -3790,18 +3786,11 @@
     }
 }
 
-static http_port_list *
-create_http_port(char *portspec)
-{
-    http_port_list *s = new http_port_list("http");
-    parse_http_port_specification(s, portspec);
-    return s;
-}
-
 void
 add_http_port(char *portspec)
 {
-    http_port_list *s = create_http_port(portspec);
+    http_port_list *s = new http_port_list("http");
+    parsePortSpecification(s, portspec);
     // we may need to merge better of the above returns a list with clones
     assert(s->next == NULL);
     s->next = Config.Sockaddr.http;
@@ -3859,7 +3848,7 @@
 }
 
 static void
-parse_http_port_list(http_port_list ** head)
+parsePortList(http_port_list ** head, const char *protocol)
 {
     char *token = strtok(NULL, w_space);
 
@@ -3868,7 +3857,8 @@
         return;
     }
 
-    http_port_list *s = create_http_port(token);
+    http_port_list *s = new http_port_list(protocol);
+    parsePortSpecification(s, token);
 
     /* parse options ... */
     while ((token = strtok(NULL, w_space))) {
@@ -3879,7 +3869,7 @@
         // clone the port options from *s to *(s->next)
         s->next = clone_http_port_list(s);
         s->next->s.SetIPv4();
-        debugs(3, 3, "http(s)_port: clone wildcard address for split-stack: " << s->s << " and " << s->next->s);
+        debugs(3, 3, protocol << "_port: clone wildcard address for split-stack: " << s->s << " and " << s->next->s);
     }
 
     while (*head)
@@ -4032,59 +4022,6 @@
     }
 }
 
-#if USE_SSL
-
-// TODO: merge better with parse_http_port_list
-static void
-parse_https_port_list(https_port_list ** head)
-{
-    char *token;
-    https_port_list *s;
-
-    token = strtok(NULL, w_space);
-
-    if (!token)
-        self_destruct();
-
-    s = new https_port_list;
-    parse_http_port_specification(&s->http, token);
-
-    /* parse options ... */
-    while ((token = strtok(NULL, w_space))) {
-        parse_http_port_option(s, token);
-    }
-
-    while (*head) {
-        http_port_list ** headTmp = &(*head)->http.next;
-        head = (https_port_list **)headTmp;
-    }
-
-    *head = s;
-}
-
-static void
-dump_https_port_list(StoreEntry * e, const char *n, const https_port_list * s)
-{
-    dump_http_port_list(e, n, s);
-}
-
-static void
-free_https_port_list(https_port_list ** head)
-{
-    free_http_port_list((http_port_list**)head);
-}
-
-#if 0
-static int
-check_null_https_port_list(const https_port_list * s)
-{
-    return NULL == s;
-}
-
-#endif
-
-#endif /* USE_SSL */
-
 void
 configFreeMemory(void)
 {
diff -u -r -N squid-3.2.0.14/src/CacheDigest.cc squid-3.2.0.15/src/CacheDigest.cc
--- squid-3.2.0.14/src/CacheDigest.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/CacheDigest.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "Store.h"
 
 #if USE_CACHE_DIGESTS
diff -u -r -N squid-3.2.0.14/src/cache_manager.cc squid-3.2.0.15/src/cache_manager.cc
--- squid-3.2.0.14/src/cache_manager.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/cache_manager.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 #include "base/TextException.h"
 #include "CacheManager.h"
 #include "comm/Connection.h"
@@ -202,8 +202,12 @@
     if (t < 1) {
         t = sscanf(url, "https://%[^/]/squid-internal-mgr/%[^?]%n?%s", host, request, &pos, params);
     }
-    if (t < 2)
-        xstrncpy(request, "menu", MAX_URL);
+    if (t < 2) {
+        if (strncmp("cache_object://",url,15)==0)
+            xstrncpy(request, "menu", MAX_URL);
+        else
+            xstrncpy(request, "index", MAX_URL);
+    }
 
 #if _SQUID_OS2_
     if (t == 2 && request[0] == '\0') {
@@ -211,7 +215,10 @@
          * emx's sscanf insists of returning 2 because it sets request
          * to null
          */
-        xstrncpy(request, "menu", MAX_URL);
+        if (strncmp("cache_object://",url,15)==0)
+            xstrncpy(request, "menu", MAX_URL);
+        else
+            xstrncpy(request, "index", MAX_URL);
     }
 #endif
 
@@ -371,6 +378,14 @@
          */
         rep->header.putAuth("Basic", actionName);
 #endif
+        // Allow cachemgr and other XHR scripts access to our version string
+        if (request->header.has(HDR_ORIGIN)) {
+            rep->header.putExt("Access-Control-Allow-Origin",request->header.getStr(HDR_ORIGIN));
+#if HAVE_AUTH_MODULE_BASIC
+            rep->header.putExt("Access-Control-Allow-Credentials","true");
+#endif
+            rep->header.putExt("Access-Control-Expose-Headers","Server");
+        }
 
         /* store the reply */
         entry->replaceHttpReply(rep);
@@ -382,11 +397,35 @@
         return;
     }
 
+    if (request->header.has(HDR_ORIGIN)) {
+        cmd->params.httpOrigin = request->header.getStr(HDR_ORIGIN);
+    }
+
     debugs(16, 2, "CacheManager: " <<
            userName << "@" <<
            client << " requesting '" <<
            actionName << "'" );
 
+    // special case: /squid-internal-mgr/ index page
+    if (!strcmp(cmd->profile->name, "index")) {
+        ErrorState err(MGR_INDEX, HTTP_OK, request);
+        err.url = xstrdup(entry->url());
+        HttpReply *rep = err.BuildHttpReply();
+        if (strncmp(rep->body.content(),"Internal Error:", 15) == 0)
+            rep->sline.status = HTTP_NOT_FOUND;
+        // Allow cachemgr and other XHR scripts access to our version string
+        if (request->header.has(HDR_ORIGIN)) {
+            rep->header.putExt("Access-Control-Allow-Origin",request->header.getStr(HDR_ORIGIN));
+#if HAVE_AUTH_MODULE_BASIC
+            rep->header.putExt("Access-Control-Allow-Credentials","true");
+#endif
+            rep->header.putExt("Access-Control-Expose-Headers","Server");
+        }
+        entry->replaceHttpReply(rep);
+        entry->complete();
+        return;
+    }
+
     if (UsingSmp() && IamWorkerProcess()) {
         // is client the right connection to pass here?
         AsyncJob::Start(new Mgr::Forwarder(client, cmd->params, request, entry));
diff -u -r -N squid-3.2.0.14/src/carp.cc squid-3.2.0.15/src/carp.cc
--- squid-3.2.0.14/src/carp.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/carp.cc	2012-02-06 04:52:31.000000000 +1300
@@ -34,7 +34,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "HttpRequest.h"
 #include "mgr/Registration.h"
 #include "Store.h"
diff -u -r -N squid-3.2.0.14/src/cbdata.cc squid-3.2.0.15/src/cbdata.cc
--- squid-3.2.0.14/src/cbdata.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/cbdata.cc	2012-02-06 04:52:31.000000000 +1300
@@ -48,7 +48,7 @@
  * when finished.
  */
 
-#include "config.h"
+#include "squid.h"
 #include "cbdata.h"
 #include "mgr/Registration.h"
 #include "Store.h"
@@ -108,7 +108,7 @@
 
     ~cbdata();
     int valid;
-    int locks;
+    int32_t locks;
     cbdata_type type;
 #if USE_CBDATA_DEBUG
 
@@ -419,7 +419,7 @@
 
     c->check(__LINE__);
 
-    assert(c->locks < 65535);
+    assert(c->locks < INT_MAX);
 
     c->locks++;
 }
diff -u -r -N squid-3.2.0.14/src/cbdata.h squid-3.2.0.15/src/cbdata.h
--- squid-3.2.0.14/src/cbdata.h	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/cbdata.h	2012-02-06 04:52:31.000000000 +1300
@@ -34,7 +34,7 @@
 #ifndef   SQUID_CBDATA_H
 #define   SQUID_CBDATA_H
 
-#include "squid.h"
+#include "squid-old.h"
 
 /**
  \defgroup CBDATAAPI Callback Data Allocator API
diff -u -r -N squid-3.2.0.14/src/cf.data.pre squid-3.2.0.15/src/cf.data.pre
--- squid-3.2.0.14/src/cf.data.pre	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/cf.data.pre	2012-02-06 04:52:31.000000000 +1300
@@ -111,6 +111,12 @@
 	Remove this line. The HTTP/1.1 feature is now fully supported by default.
 DOC_END
 
+NAME: dns_v4_fallback
+TYPE: obsolete
+DOC_START
+	Remove this line.
+DOC_END
+
 NAME: ftp_list_width
 TYPE: obsolete
 DOC_START
@@ -1361,6 +1367,28 @@
 
 
 	SSL Bump Mode Options:
+	    In addition to these options ssl-bump requires TLS/SSL options.
+
+	   generate-host-certificates[=<on|off>]
+			Dynamically create SSL server certificates for the
+			destination hosts of bumped CONNECT requests.When 
+			enabled, the cert and key options are used to sign
+			generated certificates. Otherwise generated
+			certificate will be selfsigned.
+			If there is a CA certificate lifetime of the generated 
+			certificate equals lifetime of the CA certificate. If
+			generated certificate is selfsigned lifetime is three 
+			years.
+			This option is enabled by default when ssl-bump is used.
+			See the ssl-bump option above for more information.
+			
+	   dynamic_cert_mem_cache_size=SIZE
+			Approximate total RAM size spent on cached generated
+			certificates. If set to zero, caching is disabled. The
+			default value is 4MB. An average XXX-bit certificate
+			consumes about XXX bytes of RAM.
+
+	TLS / SSL Options:
 
 	   cert=	Path to SSL certificate (PEM format).
 
@@ -1381,13 +1409,17 @@
 			      omitted the ciphers may be silently ignored
 			      by the OpenSSL library.
 
-	   options=	Various SSL engine options. The most important
+	   options=	Various SSL implementation options. The most important
 			being:
 			    NO_SSLv2  Disallow the use of SSLv2
 			    NO_SSLv3  Disallow the use of SSLv3
 			    NO_TLSv1  Disallow the use of TLSv1
 			    SINGLE_DH_USE Always create a new key when using
 				      temporary/ephemeral DH key exchanges
+			    ALL       Enable various bug workarounds
+				      suggested as "harmless" by OpenSSL
+				      Be warned that this reduces SSL/TLS
+				      strength to some attacks.
 			See OpenSSL SSL_CTX_set_options documentation for a
 			complete list of options.
 
@@ -1431,25 +1463,6 @@
 
 	   sslcontext=	SSL session ID context identifier.
 
-	   generate-host-certificates[=<on|off>]
-			Dynamically create SSL server certificates for the
-			destination hosts of bumped CONNECT requests.When 
-			enabled, the cert and key options are used to sign
-			generated certificates. Otherwise generated
-			certificate will be selfsigned.
-			If there is CA certificate life time of generated 
-			certificate equals lifetime of CA certificate. If
-			generated certificate is selfsigned lifetime is three 
-			years.
-			This option is enabled by default when SslBump is used.
-			See the sslBump option above for more information.
-			
-	   dynamic_cert_mem_cache_size=SIZE
-			Approximate total RAM size spent on cached generated
-			certificates. If set to zero, caching is disabled. The
-			default value is 4MB. An average XXX-bit certificate
-			consumes about XXX bytes of RAM.
-
 	Other Options:
 
 	   connection-auth[=on|off]
@@ -1502,90 +1515,16 @@
 DOC_START
 	Usage:  [ip:]port cert=certificate.pem [key=key.pem] [mode] [options...]
 
-	The socket address where Squid will listen for HTTPS client
-	requests.
+	The socket address where Squid will listen for client requests made
+	over TLS or SSL connections. Commonly referred to as HTTPS.
 
-	This is really only useful for situations where you are running
-	squid in accelerator mode and you want to do the SSL work at the
-	accelerator level.
+	This is most useful for situations where you are running squid in
+	accelerator mode and you want to do the SSL work at the accelerator level.
 
 	You may specify multiple socket addresses on multiple lines,
 	each with their own SSL certificate and/or options.
 
-	Modes:
-
-	   accel	Accelerator / reverse proxy mode
-
-	Omitting the mode flag causes default forward proxy mode to be used.
-
-
-	See http_port for a list of generic options
-
-
-	SSL Options:
-
-	   cert=	Path to SSL certificate (PEM format).
-
-	   key=		Path to SSL private key file (PEM format)
-			if not specified, the certificate file is
-			assumed to be a combined certificate and
-			key file.
-
-	   version=	The version of SSL/TLS supported
-			    1	automatic (default)
-			    2	SSLv2 only
-			    3	SSLv3 only
-			    4	TLSv1 only
-
-	   cipher=	Colon separated list of supported ciphers.
-
-	   options=	Various SSL engine options. The most important
-			being:
-			    NO_SSLv2  Disallow the use of SSLv2
-			    NO_SSLv3  Disallow the use of SSLv3
-			    NO_TLSv1  Disallow the use of TLSv1
-			    SINGLE_DH_USE Always create a new key when using
-				      temporary/ephemeral DH key exchanges
-			See src/ssl_support.c or OpenSSL SSL_CTX_set_options
-			documentation for a complete list of options.
-
-	   clientca=	File containing the list of CAs to use when
-			requesting a client certificate.
-
-	   cafile=	File containing additional CA certificates to
-			use when verifying client certificates. If unset
-			clientca will be used.
-
-	   capath=	Directory containing additional CA certificates
-			and CRL lists to use when verifying client certificates.
-
-	   crlfile=	File of additional CRL lists to use when verifying
-			the client certificate, in addition to CRLs stored in
-			the capath. Implies VERIFY_CRL flag below.
-
-	   dhparams=	File containing DH parameters for temporary/ephemeral
-			DH key exchanges.
-
-	   sslflags=	Various flags modifying the use of SSL:
-			    DELAYED_AUTH
-				Don't request client certificates
-				immediately, but wait until acl processing
-				requires a certificate (not yet implemented).
-			    NO_DEFAULT_CA
-				Don't use the default CA lists built in
-				to OpenSSL.
-			    NO_SESSION_REUSE
-				Don't allow for session reuse. Each connection
-				will result in a new SSL session.
-			    VERIFY_CRL
-				Verify CRL lists when accepting client
-				certificates.
-			    VERIFY_CRL_ALL
-				Verify CRL lists for all certificates in the
-				client certificate chain.
-
-	   sslcontext=	SSL session ID context identifier.
-
+	See http_port for a list of available options.
 DOC_END
 
 NAME: tcp_outgoing_tos tcp_outgoing_ds tcp_outgoing_dscp
@@ -1802,25 +1741,48 @@
 DOC_START
 	Regardless of this option setting, when dealing with intercepted
 	traffic, Squid always verifies that the destination IP address matches
-	the Host header domain or IP (called 'authority form URL'). Squid
-	responds with an HTTP 409 (Conflict) error page and logs a security
-	warning if there is no match.
-	
-	When set to ON, Squid verifies that the destination IP address matches
-	the Host header for forward-proxy and reverse-proxy traffic as well. For
-	those traffic types, Squid also enables the following checks, comparing
-	the corresponding Host header and Request-URI components:
-	
-	 * The host names (domain or IP) must be identical,
-	   but valueless or missing Host header disables all checks.
-	   For the two host names to match, both must be either IP or FQDN.
-	
-	 * Port numbers must be identical,
-	   but if a port is missing, the scheme-default port is assumed.
+	the Host header domain or IP (called 'authority form URL').
 	
 	This enforcement is performed to satisfy a MUST-level requirement in
 	RFC 2616 section 14.23: "The Host field value MUST represent the naming
 	authority of the origin server or gateway given by the original URL".
+	
+	When set to ON:
+		Squid always responds with an HTTP 409 (Conflict) error
+		page and logs a security warning if there is no match.
+	
+		Squid verifies that the destination IP address matches
+		the Host header for forward-proxy and reverse-proxy traffic
+		as well. For those traffic types, Squid also enables the
+		following checks, comparing the corresponding Host header
+		and Request-URI components:
+	
+		 * The host names (domain or IP) must be identical,
+		   but valueless or missing Host header disables all checks.
+		   For the two host names to match, both must be either IP
+		   or FQDN.
+	
+		 * Port numbers must be identical, but if a port is missing
+		   the scheme-default port is assumed.
+	
+	
+	When set to OFF (the default):
+		Squid allows suspicious requests to continue but logs a
+		security warning and blocks caching of the response.
+	
+		 * Forward-proxy traffic is not checked at all.
+	
+		 * Reverse-proxy traffic is not checked at all.
+	
+		 * Intercepted traffic which passes verification is handled
+		   normally.
+	
+		For now it also forces suspicious requests to go DIRECT to the
+		original destination, overriding client_dst_passthru for
+		intercepted requests which fail Host: verification.
+	
+		For now suspicious intercepted CONNECT requests are always
+		responded to with an HTTP 409 (Conflict) error page.
 DOC_END
 
 NAME: client_dst_passthru
@@ -1911,18 +1873,24 @@
 LOC: Config.ssl_client.options
 TYPE: string
 DOC_START
-	SSL engine options to use when proxying https:// URLs
+	SSL implementation options to use when proxying https:// URLs
 	
 	The most important being:
 
-		NO_SSLv2  Disallow the use of SSLv2
-		NO_SSLv3  Disallow the use of SSLv3
-		NO_TLSv1  Disallow the use of TLSv1
-		SINGLE_DH_USE
-			Always create a new key when using
-			temporary/ephemeral DH key exchanges
+	    NO_SSLv2  Disallow the use of SSLv2
+	    NO_SSLv3  Disallow the use of SSLv3
+	    NO_TLSv1  Disallow the use of TLSv1
+	    SINGLE_DH_USE
+		      Always create a new key when using temporary/ephemeral
+		      DH key exchanges
+	    SSL_OP_NO_TICKET
+		      Disable use of RFC5077 session tickets. Some servers
+		      may have problems understanding the TLS extension due
+		      to ambiguous specification in RFC4507.
+	    ALL       Enable various bug workarounds suggested as "harmless"
+		      by OpenSSL. Be warned that this may reduce SSL/TLS
+		      strength to some attacks.
 	
-	These options vary depending on your SSL engine.
 	See the OpenSSL SSL_CTX_set_options documentation for a
 	complete list of possible options.
 DOC_END
@@ -2372,12 +2340,21 @@
 	sslcipher=...	The list of valid SSL ciphers to use when connecting
 			to this peer.
 	
-	ssloptions=... 	Specify various SSL engine options:
-				NO_SSLv2  Disallow the use of SSLv2
-				NO_SSLv3  Disallow the use of SSLv3
-				NO_TLSv1  Disallow the use of TLSv1
-			See src/ssl_support.c or the OpenSSL documentation for
-			a more complete list.
+	ssloptions=... 	Specify various SSL implementation options:
+
+			    NO_SSLv2  Disallow the use of SSLv2
+			    NO_SSLv3  Disallow the use of SSLv3
+			    NO_TLSv1  Disallow the use of TLSv1
+			    SINGLE_DH_USE
+				      Always create a new key when using
+				      temporary/ephemeral DH key exchanges
+			    ALL       Enable various bug workarounds
+				      suggested as "harmless" by OpenSSL
+				      Be warned that this reduces SSL/TLS
+				      strength to some attacks.
+
+			See the OpenSSL SSL_CTX_set_options documentation for a
+			more complete list.
 	
 	sslcafile=... 	A file containing additional CA certificates to use
 			when verifying the peer certificate.
@@ -7133,7 +7110,7 @@
 
 NAME: cache_dns_program
 TYPE: string
-IFDEF: USE_DNSSERVERS
+IFDEF: USE_DNSHELPER
 DEFAULT: @DEFAULT_DNSSERVER@
 LOC: Config.Program.dnsserver
 DOC_START
@@ -7142,7 +7119,7 @@
 
 NAME: dns_children
 TYPE: HelperChildConfig
-IFDEF: USE_DNSSERVERS
+IFDEF: USE_DNSHELPER
 DEFAULT: 32 startup=1 idle=1
 LOC: Config.dnsChildren
 DOC_START
@@ -7176,7 +7153,7 @@
 TYPE: time_msec
 DEFAULT: 5 seconds
 LOC: Config.Timeout.idns_retransmit
-IFDEF: !USE_DNSSERVERS
+IFDEF: !USE_DNSHELPER
 DOC_START
 	Initial retransmit interval for DNS queries. The interval is
 	doubled each time all configured DNS servers have been tried.
@@ -7186,7 +7163,7 @@
 TYPE: time_msec
 DEFAULT: 30 seconds
 LOC: Config.Timeout.idns_query
-IFDEF: !USE_DNSSERVERS
+IFDEF: !USE_DNSHELPER
 DOC_START
 	DNS Query timeout. If no response is received to a DNS query
 	within this time all DNS servers for the queried domain
@@ -7197,7 +7174,7 @@
 TYPE: b_ssize_t
 DEFAULT: none
 LOC: Config.dns.packet_max
-IFDEF: !USE_DNSSERVERS
+IFDEF: !USE_DNSHELPER
 DOC_START
 	Maximum number of bytes packet size to advertise via EDNS.
 	Set to "none" to disable EDNS large packet support.
@@ -7298,7 +7275,7 @@
 TYPE: onoff
 LOC: Config.onoff.ignore_unknown_nameservers
 DEFAULT: on
-IFDEF: !USE_DNSSERVERS
+IFDEF: !USE_DNSHELPER
 DOC_START
 	By default Squid checks that DNS responses are received
 	from the same IP addresses they are sent to.  If they
@@ -7307,32 +7284,11 @@
 	nameservers by setting this option to 'off'.
 DOC_END
 
-NAME: dns_v4_fallback
-TYPE: onoff
-DEFAULT: on
-LOC: Config.onoff.dns_require_A
-IFDEF: !USE_DNSSERVERS
-DOC_START
-	Standard practice with DNS is to lookup either A or AAAA records
-	and use the results if it succeeds. Only looking up the other if
-	the first attempt fails or otherwise produces no results.
-
-	That policy however will cause squid to produce error pages for some
-	servers that advertise AAAA but are unreachable over IPv6.
-
-	If this is ON  squid will always lookup both AAAA and A, using both.
-	If this is OFF squid will lookup AAAA and only try A if none found.
-
-	WARNING: There are some possibly unwanted side-effects with this on:
-		*) Doubles the load placed by squid on the DNS network.
-		*) May negatively impact connection delay times.
-DOC_END
-
 NAME: dns_v4_first
 TYPE: onoff
 DEFAULT: off
 LOC: Config.dns.v4_first
-IFDEF: !USE_DNSSERVERS
+IFDEF: !USE_DNSHELPER
 DOC_START
 	With the IPv6 Internet being as fast or faster than IPv4 Internet
 	for most networks Squid prefers to contact websites over IPv6.
diff -u -r -N squid-3.2.0.14/src/cf_gen_defines squid-3.2.0.15/src/cf_gen_defines
--- squid-3.2.0.14/src/cf_gen_defines	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/cf_gen_defines	2012-02-06 04:52:31.000000000 +1300
@@ -15,8 +15,8 @@
 	define["SQUID_SNMP"]="--enable-snmp"
 	define["USE_ADAPTATION"]="--enable-ecap or --enable-icap-client"
 	define["USE_CACHE_DIGESTS"]="--enable-cache-digests"
-	define["USE_DNSSERVERS"]="--disable-internal-dns"
-	define["!USE_DNSSERVERS"]="--enable-internal-dns"
+	define["USE_DNSHELPER"]="--disable-internal-dns"
+	define["!USE_DNSHELPER"]="--enable-internal-dns"
 	define["USE_ECAP"]="--enable-ecap"
 	define["USE_ERR_LOCALES"]="--enable-auto-locale"
 	define["USE_HTCP"]="--enable-htcp"
diff -u -r -N squid-3.2.0.14/src/ChunkedCodingParser.cc squid-3.2.0.15/src/ChunkedCodingParser.cc
--- squid-3.2.0.14/src/ChunkedCodingParser.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/ChunkedCodingParser.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "squid.h"
+#include "squid-old.h"
 #include "base/TextException.h"
 #include "Parsing.h"
 #include "ChunkedCodingParser.h"
diff -u -r -N squid-3.2.0.14/src/client_db.cc squid-3.2.0.15/src/client_db.cc
--- squid-3.2.0.14/src/client_db.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/client_db.cc	2012-02-06 04:52:31.000000000 +1300
@@ -32,7 +32,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "event.h"
 #include "format/Token.h"
 #include "ClientInfo.h"
diff -u -r -N squid-3.2.0.14/src/ClientDelayConfig.cc squid-3.2.0.15/src/ClientDelayConfig.cc
--- squid-3.2.0.14/src/ClientDelayConfig.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/ClientDelayConfig.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,5 +1,5 @@
-#include "config.h"
 #include "squid.h"
+#include "squid-old.h"
 #include "ConfigParser.h"
 #include "ClientDelayConfig.h"
 #include "Parsing.h"
diff -u -r -N squid-3.2.0.14/src/client_side.cc squid-3.2.0.15/src/client_side.cc
--- squid-3.2.0.14/src/client_side.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/client_side.cc	2012-02-06 04:52:31.000000000 +1300
@@ -81,7 +81,7 @@
  * data flow.
  */
 
-#include "squid.h"
+#include "squid-old.h"
 
 #include "acl/FilledChecklist.h"
 #if USE_AUTH
@@ -2023,15 +2023,6 @@
             url = (char *) "/";
     }
 
-    if (internalCheck(url)) {
-        /* prepend our name & port */
-        http->uri = xstrdup(internalLocalUri(NULL, url));
-        // We just re-wrote the URL. Must replace the Host: header.
-        //  But have not parsed there yet!! flag for local-only handling.
-        http->flags.internal = 1;
-        return;
-    }
-
     if (vport < 0)
         vport = http->getConn()->clientConnection->local.GetPort();
 
@@ -2280,15 +2271,17 @@
         /* intercept or transparent mode, properly working with no failures */
         prepareTransparentURL(csd, http, url, req_hdr);
 
-    } else if (csd->port->accel || csd->switchedToHttps()) {
-        /* accelerator mode */
-        prepareAcceleratedURL(csd, http, url, req_hdr);
-
     } else if (internalCheck(url)) {
         /* internal URL mode */
         /* prepend our name & port */
         http->uri = xstrdup(internalLocalUri(NULL, url));
-        http->flags.accel = 1;
+        // We just re-wrote the URL. Must replace the Host: header.
+        //  But have not parsed there yet!! flag for local-only handling.
+        http->flags.internal = 1;
+
+    } else if (csd->port->accel || csd->switchedToHttps()) {
+        /* accelerator mode */
+        prepareAcceleratedURL(csd, http, url, req_hdr);
     }
 
     if (!http->uri) {
@@ -2547,6 +2540,12 @@
     request->flags.sslBumped = conn->switchedToHttps();
     request->flags.ignore_cc = conn->port->ignore_cc;
     request->flags.no_direct = request->flags.accelerated ? !conn->port->allow_direct : 0;
+#if USE_AUTH
+    if (request->flags.sslBumped) {
+        if (conn->auth_user_request != NULL)
+            request->auth_user_request = conn->auth_user_request;
+    }
+#endif
 
     /** \par
      * If transparent or interception mode is working clone the transparent and interception flags
@@ -2702,7 +2701,7 @@
      * be freed and the above connNoteUseOfBuffer() would hit an
      * assertion, not to mention that we were accessing freed memory.
      */
-    if (http->request->flags.resetTCP() && Comm::IsConnOpen(conn->clientConnection)) {
+    if (request && request->flags.resetTCP() && Comm::IsConnOpen(conn->clientConnection)) {
         debugs(33, 3, HERE << "Sending TCP RST on " << conn->clientConnection);
         conn->flags.readMore = false;
         comm_reset_close(conn->clientConnection);
@@ -3431,7 +3430,7 @@
 static void
 httpsAccept(const CommAcceptCbParams &params)
 {
-    https_port_list *s = (https_port_list *)params.data;
+    http_port_list *s = (http_port_list *)params.data;
 
     if (params.flag != COMM_OK) {
         // Its possible the call was still queued when the client disconnected
@@ -3447,14 +3446,14 @@
     debugs(33, 4, HERE << params.conn << " accepted, starting SSL negotiation.");
     fd_note(params.conn->fd, "client https connect");
 
-    if (s->http.tcp_keepalive.enabled) {
-        commSetTcpKeepalive(params.conn->fd, s->http.tcp_keepalive.idle, s->http.tcp_keepalive.interval, s->http.tcp_keepalive.timeout);
+    if (s->tcp_keepalive.enabled) {
+        commSetTcpKeepalive(params.conn->fd, s->tcp_keepalive.idle, s->tcp_keepalive.interval, s->tcp_keepalive.timeout);
     }
 
     incoming_sockets_accepted++;
 
     // Socket is ready, setup the connection manager to start using it
-    ConnStateData *connState = connStateCreate(params.conn, &s->http);
+    ConnStateData *connState = connStateCreate(params.conn, s);
 
     typedef CommCbMemFunT<ConnStateData, CommTimeoutCbParams> TimeoutDialer;
     AsyncCall::Pointer timeoutCall =  JobCallback(33, 5,
@@ -3643,12 +3642,12 @@
 
 #if USE_SSL
         if (s->sslBump && !Config.accessList.ssl_bump) {
-            debugs(33, DBG_IMPORTANT, "WARNING: No ssl_bump configured. Disabling ssl-bump on " << s->protocol << "_port " << s->http.s);
+            debugs(33, DBG_IMPORTANT, "WARNING: No ssl_bump configured. Disabling ssl-bump on " << s->protocol << "_port " << s->s);
             s->sslBump = 0;
         }
 
         if (s->sslBump && !s->staticSslContext && !s->generateHostCertificates) {
-            debugs(1, DBG_IMPORTANT, "Will not bump SSL at http_port " << s->http.s << " due to SSL initialization failure.");
+            debugs(1, DBG_IMPORTANT, "Will not bump SSL at http_port " << s->s << " due to SSL initialization failure.");
             s->sslBump = 0;
         }
         if (s->sslBump) {
@@ -3680,9 +3679,9 @@
 static void
 clientHttpsConnectionsOpen(void)
 {
-    https_port_list *s;
+    http_port_list *s;
 
-    for (s = Config.Sockaddr.https; s; s = (https_port_list *)s->http.next) {
+    for (s = Config.Sockaddr.https; s; s = s->next) {
         if (MAXHTTPPORTS == NHttpSockets) {
             debugs(1, 1, "Ignoring 'https_port' lines exceeding the limit.");
             debugs(1, 1, "The limit is " << MAXHTTPPORTS << " HTTPS ports.");
@@ -3690,16 +3689,16 @@
         }
 
         if (!s->staticSslContext) {
-            debugs(1, 1, "Ignoring https_port " << s->http.s <<
+            debugs(1, 1, "Ignoring https_port " << s->s <<
                    " due to SSL initialization failure.");
             continue;
         }
 
         // Fill out a Comm::Connection which IPC will open as a listener for us
-        s->http.listenConn = new Comm::Connection;
-        s->http.listenConn->local = s->http.s;
-        s->http.listenConn->flags = COMM_NONBLOCKING | (s->http.spoof_client_ip ? COMM_TRANSPARENT : 0) |
-                                    (s->http.intercepted ? COMM_INTERCEPTION : 0);
+        s->listenConn = new Comm::Connection;
+        s->listenConn->local = s->s;
+        s->listenConn->flags = COMM_NONBLOCKING | (s->spoof_client_ip ? COMM_TRANSPARENT : 0) |
+                               (s->intercepted ? COMM_INTERCEPTION : 0);
 
         // setup the subscriptions such that new connections accepted by listenConn are handled by HTTPS
         typedef CommCbFunPtrCallT<CommAcceptCbPtrFun> AcceptCall;
@@ -3708,7 +3707,7 @@
 
         AsyncCall::Pointer listenCall = asyncCall(33, 2, "clientListenerConnectionOpened",
                                         ListeningStartedDialer(&clientListenerConnectionOpened,
-                                                               &s->http, Ipc::fdnHttpsSocket, sub));
+                                                               s, Ipc::fdnHttpsSocket, sub));
         Ipc::StartListening(SOCK_STREAM, IPPROTO_TCP, s->listenConn, Ipc::fdnHttpsSocket, listenCall);
         HttpSockets[NHttpSockets++] = -1;
     }
diff -u -r -N squid-3.2.0.14/src/client_side.h squid-3.2.0.15/src/client_side.h
--- squid-3.2.0.14/src/client_side.h	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/client_side.h	2012-02-06 04:52:31.000000000 +1300
@@ -228,7 +228,7 @@
      * note this is ONLY connection based because NTLM and Negotiate is against HTTP spec.
      * the user details for connection based authentication
      */
-    AuthUserRequest::Pointer auth_user_request;
+    Auth::UserRequest::Pointer auth_user_request;
 #endif
 
     /**
diff -u -r -N squid-3.2.0.14/src/client_side_reply.cc squid-3.2.0.15/src/client_side_reply.cc
--- squid-3.2.0.14/src/client_side_reply.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/client_side_reply.cc	2012-02-06 04:52:31.000000000 +1300
@@ -31,13 +31,13 @@
  *  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111, USA.
  *
  */
-#include "config.h"
+#include "squid.h"
 
 /* for ClientActiveRequests global */
 #include "dlink.h"
 
 /* old includes without reasons given. */
-#include "squid.h"
+#include "squid-old.h"
 #include "acl/FilledChecklist.h"
 #include "acl/Gadgets.h"
 #if USE_AUTH
@@ -102,7 +102,7 @@
     err_type err, http_status status, const HttpRequestMethod& method, char const *uri,
     Ip::Address &addr, HttpRequest * failedrequest, const char *unparsedrequest,
 #if USE_AUTH
-    AuthUserRequest::Pointer auth_user_request
+    Auth::UserRequest::Pointer auth_user_request
 #else
     void*
 #endif
@@ -367,6 +367,7 @@
     // origin replied 304
     if (status == HTTP_NOT_MODIFIED) {
         http->logType = LOG_TCP_REFRESH_UNMODIFIED;
+        http->request->flags.stale_if_hit = 0; // old_entry is no longer stale
 
         // update headers on existing entry
         old_rep->updateOnNotModified(http->storeEntry()->getReply());
@@ -1565,15 +1566,11 @@
       */
     if (r->flags.nocache) {
 
-#if USE_DNSSERVERS
-
+#if USE_DNSHELPER
         ipcacheInvalidate(r->GetHost());
-
 #else
-
         ipcacheInvalidateNegative(r->GetHost());
-
-#endif /* USE_DNSSERVERS */
+#endif /* USE_DNSHELPER */
 
     }
 
@@ -1581,15 +1578,11 @@
 
     else if (r->flags.nocache_hack) {
 
-#if USE_DNSSERVERS
-
+#if USE_DNSHELPER
         ipcacheInvalidate(r->GetHost());
-
 #else
-
         ipcacheInvalidateNegative(r->GetHost());
-
-#endif /* USE_DNSSERVERS */
+#endif /* USE_DNSHELPER */
 
     }
 
diff -u -r -N squid-3.2.0.14/src/client_side_reply.h squid-3.2.0.15/src/client_side_reply.h
--- squid-3.2.0.14/src/client_side_reply.h	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/client_side_reply.h	2012-02-06 04:52:31.000000000 +1300
@@ -73,7 +73,7 @@
     int storeNotOKTransferDone() const;
     void setReplyToError(err_type, http_status, const HttpRequestMethod&, char const *, Ip::Address &, HttpRequest *, const char *,
 #if USE_AUTH
-                         AuthUserRequest::Pointer);
+                         Auth::UserRequest::Pointer);
 #else
                          void * unused);
 #endif
diff -u -r -N squid-3.2.0.14/src/client_side_request.cc squid-3.2.0.15/src/client_side_request.cc
--- squid-3.2.0.14/src/client_side_request.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/client_side_request.cc	2012-02-06 04:52:31.000000000 +1300
@@ -42,7 +42,7 @@
  * From that point on it's up to reply management.
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "acl/FilledChecklist.h"
 #include "acl/Gadgets.h"
 #if USE_ADAPTATION
@@ -553,6 +553,21 @@
 void
 ClientRequestContext::hostHeaderVerifyFailed(const char *A, const char *B)
 {
+    // IP address validation for Host: failed. Admin wants to ignore them.
+    // NP: we do not yet handle CONNECT tunnels well, so ignore for them
+    if (!Config.onoff.hostStrictVerify && http->request->method != METHOD_CONNECT) {
+        debugs(85, 3, "SECURITY ALERT: Host header forgery detected on " << http->getConn()->clientConnection <<
+               " (" << A << " does not match " << B << ") on URL: " << urlCanonical(http->request));
+
+        // NP: it is tempting to use 'flags.nocache' but that is all about READing cache data.
+        // The problems here are about WRITE for new cache content, which means flags.cachable
+        http->request->flags.cachable = 0; // MUST NOT cache (for now)
+        // XXX: when we have updated the cache key to base on raw-IP + URI this cacheable limit can go.
+        http->request->flags.hierarchical = 0; // MUST NOT pass to peers (for now)
+        // XXX: when we have sorted out the best way to relay requests properly to peers this hierarchical limit can go.
+        return;
+    }
+
     debugs(85, DBG_IMPORTANT, "SECURITY ALERT: Host header forgery detected on " <<
            http->getConn()->clientConnection << " (" << A << " does not match " << B << ")");
     debugs(85, DBG_IMPORTANT, "SECURITY ALERT: By user agent: " << http->request->header.getStr(HDR_USER_AGENT));
@@ -562,7 +577,7 @@
     clientStreamNode *node = (clientStreamNode *)http->client_stream.tail->prev->data;
     clientReplyContext *repContext = dynamic_cast<clientReplyContext *>(node->data.getRaw());
     assert (repContext);
-    repContext->setReplyToError(ERR_INVALID_REQ, HTTP_CONFLICT,
+    repContext->setReplyToError(ERR_CONFLICT_HOST, HTTP_CONFLICT,
                                 http->request->method, NULL,
                                 http->getConn()->clientConnection->remote,
                                 http->request,
@@ -657,6 +672,7 @@
     } else {
         // Okay no problem.
         debugs(85, 3, HERE << "validate passed.");
+        http->request->flags.hostVerified = 1;
         http->doCallouts();
     }
     safe_free(hostB);
@@ -764,7 +780,10 @@
 
         if (require_auth) {
 #if USE_AUTH
-            if (!http->flags.accel) {
+            if (http->request->flags.sslBumped) {
+                /*SSL Bumped request, authentication is not possible*/
+                status = HTTP_FORBIDDEN;
+            } else if (!http->flags.accel) {
                 /* Proxy authorisation needed */
                 status = HTTP_PROXY_AUTHENTICATION_REQUIRED;
             } else {
@@ -879,6 +898,10 @@
     HttpRequestMethod method = request->method;
     const wordlist *p = NULL;
 
+    // intercepted requests MUST NOT (yet) be sent to peers unless verified
+    if (!request->flags.hostVerified && (request->flags.intercepted || request->flags.spoof_client_ip))
+        return 0;
+
     /*
      * IMS needs a private key, so we can use the hierarchy for IMS only if our
      * neighbors support private keys
@@ -1369,6 +1392,11 @@
         return;
     }
 
+#if USE_AUTH
+    // Preserve authentication info for the ssl-bumped request
+    if (request->auth_user_request != NULL)
+        getConn()->auth_user_request = request->auth_user_request;
+#endif
     getConn()->switchToHttps(request->GetHost());
 }
 
diff -u -r -N squid-3.2.0.14/src/client_side_request.h squid-3.2.0.15/src/client_side_request.h
--- squid-3.2.0.14/src/client_side_request.h	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/client_side_request.h	2012-02-06 04:52:31.000000000 +1300
@@ -35,7 +35,7 @@
 #ifndef SQUID_CLIENTSIDEREQUEST_H
 #define SQUID_CLIENTSIDEREQUEST_H
 
-#include "squid.h"
+#include "squid-old.h"
 #include "HttpHeader.h"
 #include "clientStream.h"
 #include "client_side.h"
diff -u -r -N squid-3.2.0.14/src/clientStream.cc squid-3.2.0.15/src/clientStream.cc
--- squid-3.2.0.14/src/clientStream.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/clientStream.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "clientStream.h"
 #include "HttpReply.h"
 #include "HttpRequest.h"
diff -u -r -N squid-3.2.0.14/src/comm/AcceptLimiter.cc squid-3.2.0.15/src/comm/AcceptLimiter.cc
--- squid-3.2.0.14/src/comm/AcceptLimiter.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/comm/AcceptLimiter.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "config.h"
+#include "squid.h"
 #include "comm/AcceptLimiter.h"
 #include "comm/Connection.h"
 #include "comm/TcpAcceptor.h"
diff -u -r -N squid-3.2.0.14/src/comm/Connection.cc squid-3.2.0.15/src/comm/Connection.cc
--- squid-3.2.0.14/src/comm/Connection.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/comm/Connection.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "config.h"
+#include "squid.h"
 #include "cbdata.h"
 #include "comm.h"
 #include "comm/Connection.h"
diff -u -r -N squid-3.2.0.14/src/comm/ConnOpener.cc squid-3.2.0.15/src/comm/ConnOpener.cc
--- squid-3.2.0.14/src/comm/ConnOpener.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/comm/ConnOpener.cc	2012-02-06 04:52:31.000000000 +1300
@@ -2,7 +2,7 @@
  * DEBUG: section 05    Socket Connection Opener
  */
 
-#include "config.h"
+#include "squid.h"
 #include "comm/ConnOpener.h"
 #include "comm/Connection.h"
 #include "comm/Loops.h"
diff -u -r -N squid-3.2.0.14/src/comm/IoCallback.cc squid-3.2.0.15/src/comm/IoCallback.cc
--- squid-3.2.0.14/src/comm/IoCallback.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/comm/IoCallback.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "config.h"
+#include "squid.h"
 #include "ClientInfo.h"
 #include "comm/Connection.h"
 #include "comm/IoCallback.h"
diff -u -r -N squid-3.2.0.14/src/comm/ModDevPoll.cc squid-3.2.0.15/src/comm/ModDevPoll.cc
--- squid-3.2.0.14/src/comm/ModDevPoll.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/comm/ModDevPoll.cc	2012-02-06 04:52:31.000000000 +1300
@@ -50,11 +50,11 @@
  * modules from creating several versions of the same function simultaneously.
  */
 
-#include "config.h"
+#include "squid.h"
 
 #if USE_DEVPOLL
 
-#include "squid.h"
+#include "squid-old.h"
 #include "comm/Loops.h"
 #include "fde.h"
 #include "mgr/Registration.h"
diff -u -r -N squid-3.2.0.14/src/comm/ModEpoll.cc squid-3.2.0.15/src/comm/ModEpoll.cc
--- squid-3.2.0.14/src/comm/ModEpoll.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/comm/ModEpoll.cc	2012-02-06 04:52:31.000000000 +1300
@@ -51,11 +51,11 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 
 #if USE_EPOLL
 
-#include "squid.h"
+#include "squid-old.h"
 #include "comm/Loops.h"
 #include "fde.h"
 #include "mgr/Registration.h"
diff -u -r -N squid-3.2.0.14/src/comm/ModKqueue.cc squid-3.2.0.15/src/comm/ModKqueue.cc
--- squid-3.2.0.14/src/comm/ModKqueue.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/comm/ModKqueue.cc	2012-02-06 04:52:31.000000000 +1300
@@ -52,11 +52,11 @@
  * so deferred reads aren't required.
  *  -- adrian
  */
-#include "config.h"
+#include "squid.h"
 
 #if USE_KQUEUE
 
-#include "squid.h"
+#include "squid-old.h"
 #include "comm/Loops.h"
 #include "fde.h"
 #include "Store.h"
diff -u -r -N squid-3.2.0.14/src/comm/ModPoll.cc squid-3.2.0.15/src/comm/ModPoll.cc
--- squid-3.2.0.14/src/comm/ModPoll.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/comm/ModPoll.cc	2012-02-06 04:52:31.000000000 +1300
@@ -30,11 +30,11 @@
  *  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111, USA.
  *
  */
-#include "config.h"
+#include "squid.h"
 
 #if USE_POLL
 
-#include "squid.h"
+#include "squid-old.h"
 #include "comm/Connection.h"
 #include "comm/Loops.h"
 #include "fde.h"
diff -u -r -N squid-3.2.0.14/src/comm/ModSelect.cc squid-3.2.0.15/src/comm/ModSelect.cc
--- squid-3.2.0.14/src/comm/ModSelect.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/comm/ModSelect.cc	2012-02-06 04:52:31.000000000 +1300
@@ -30,11 +30,11 @@
  *  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111, USA.
  *
  */
-#include "config.h"
+#include "squid.h"
 
 #if USE_SELECT
 
-#include "squid.h"
+#include "squid-old.h"
 #include "comm/Connection.h"
 #include "comm/Loops.h"
 #include "ICP.h"
diff -u -r -N squid-3.2.0.14/src/comm/ModSelectWin32.cc squid-3.2.0.15/src/comm/ModSelectWin32.cc
--- squid-3.2.0.14/src/comm/ModSelectWin32.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/comm/ModSelectWin32.cc	2012-02-06 04:52:31.000000000 +1300
@@ -31,11 +31,11 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 
 #if USE_SELECT_WIN32
 
-#include "squid.h"
+#include "squid-old.h"
 #include "comm/Loops.h"
 #include "fde.h"
 #include "mgr/Registration.h"
diff -u -r -N squid-3.2.0.14/src/comm/TcpAcceptor.cc squid-3.2.0.15/src/comm/TcpAcceptor.cc
--- squid-3.2.0.14/src/comm/TcpAcceptor.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/comm/TcpAcceptor.cc	2012-02-06 04:52:31.000000000 +1300
@@ -32,7 +32,7 @@
  * Copyright (c) 2003, Robert Collins <robertc@squid-cache.org>
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "base/TextException.h"
 #include "CommCalls.h"
 #include "comm/AcceptLimiter.h"
diff -u -r -N squid-3.2.0.14/src/comm/Write.cc squid-3.2.0.15/src/comm/Write.cc
--- squid-3.2.0.14/src/comm/Write.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/comm/Write.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "config.h"
+#include "squid.h"
 #if USE_DELAY_POOLS
 #include "ClientInfo.h"
 #endif
diff -u -r -N squid-3.2.0.14/src/CommCalls.cc squid-3.2.0.15/src/CommCalls.cc
--- squid-3.2.0.14/src/CommCalls.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/CommCalls.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "squid.h"
+#include "squid-old.h"
 #include "fde.h"
 #include "comm/Connection.h"
 #include "CommCalls.h"
diff -u -r -N squid-3.2.0.14/src/comm.cc squid-3.2.0.15/src/comm.cc
--- squid-3.2.0.14/src/comm.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/comm.cc	2012-02-06 04:52:31.000000000 +1300
@@ -32,7 +32,7 @@
  * Copyright (c) 2003, Robert Collins <robertc@squid-cache.org>
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "base/AsyncCall.h"
 #include "StoreIOBuffer.h"
 #include "comm.h"
@@ -727,45 +727,19 @@
      */
 }
 
-// Legacy pre-AsyncCalls API for FD timeouts.
-int
-commSetTimeout(int fd, int timeout, CTCB * handler, void *data)
-{
-    AsyncCall::Pointer call;
-    debugs(5, 3, HERE << "FD " << fd << " timeout " << timeout);
-    if (handler != NULL)
-        call=commCbCall(5,4, "SomeTimeoutHandler", CommTimeoutCbPtrFun(handler, data));
-    else
-        call = NULL;
-    return commSetTimeout(fd, timeout, call);
-}
-
-// Legacy pre-Comm::Connection API for FD timeouts
-// still used by non-socket FD code dealing with pipes and IPC sockets.
-int
-commSetTimeout(int fd, int timeout, AsyncCall::Pointer &callback)
+// XXX: now that raw-FD timeouts are only unset for pipes and files this SHOULD be a no-op.
+// With handler already unset. Leaving this present until that can be verified for all code paths.
+void
+commUnsetFdTimeout(int fd)
 {
-    debugs(5, 3, HERE << "FD " << fd << " timeout " << timeout);
+    debugs(5, 3, HERE << "Remove timeout for FD " << fd);
     assert(fd >= 0);
     assert(fd < Squid_MaxFD);
     fde *F = &fd_table[fd];
     assert(F->flags.open);
 
-    if (timeout < 0) {
-        F->timeoutHandler = NULL;
-        F->timeout = 0;
-    } else {
-        if (callback != NULL) {
-            typedef CommTimeoutCbParams Params;
-            Params &params = GetCommParams<Params>(callback);
-            params.fd = fd;
-            F->timeoutHandler = callback;
-        }
-
-        F->timeout = squid_curtime + (time_t) timeout;
-    }
-
-    return F->timeout;
+    F->timeoutHandler = NULL;
+    F->timeout = 0;
 }
 
 int
@@ -962,10 +936,6 @@
         // If call is not canceled schedule it for execution else ignore it
         if (!call->canceled()) {
             debugs(5, 5, "commCallCloseHandlers: ch->handler=" << call);
-            // XXX: this should not be needed. Params can be set by the call creator
-            typedef CommCloseCbParams Params;
-            Params &params = GetCommParams<Params>(call);
-            params.fd = fd;
             ScheduleCallHere(call);
         }
     }
@@ -986,10 +956,10 @@
 }
 
 static void
-commLingerTimeout(int fd, void *unused)
+commLingerTimeout(const FdeCbParams &params)
 {
-    debugs(5, 3, "commLingerTimeout: FD " << fd);
-    comm_close(fd);
+    debugs(5, 3, "commLingerTimeout: FD " << params.fd);
+    comm_close(params.fd);
 }
 
 /*
@@ -1009,7 +979,18 @@
     }
 
     fd_note(fd, "lingering close");
-    commSetTimeout(fd, 10, commLingerTimeout, NULL);
+    AsyncCall::Pointer call = commCbCall(5,4, "commLingerTimeout", FdeCbPtrFun(commLingerTimeout, NULL));
+
+    debugs(5, 3, HERE << "FD " << fd << " timeout " << timeout);
+    assert(fd_table[fd].flags.open);
+    if (callback != NULL) {
+        typedef FdeCbParams Params;
+        Params &params = GetCommParams<Params>(callback);
+        params.fd = fd;
+        fd_table[fd].timeoutHandler = callback;
+        fd_table[fd].timeout = squid_curtime + static_cast<time_t>(10);
+    }
+
     Comm::SetSelect(fd, COMM_SELECT_READ, commLingerClose, NULL, 0);
 }
 
@@ -1130,7 +1111,7 @@
     // a half-closed fd may lack a reader, so we stop monitoring explicitly
     if (commHasHalfClosedMonitor(fd))
         commStopHalfClosedMonitor(fd);
-    commSetTimeout(fd, -1, NULL, NULL);
+    commUnsetFdTimeout(fd);
 
     // notify read/write handlers after canceling select reservations, if any
     if (COMMIO_FD_WRITECB(fd)->active()) {
diff -u -r -N squid-3.2.0.14/src/comm.h squid-3.2.0.15/src/comm.h
--- squid-3.2.0.14/src/comm.h	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/comm.h	2012-02-06 04:52:31.000000000 +1300
@@ -1,7 +1,7 @@
 #ifndef __COMM_H__
 #define __COMM_H__
 
-#include "squid.h"
+#include "squid-old.h"
 #include "AsyncEngine.h"
 #include "base/AsyncCall.h"
 #include "CommCalls.h"
@@ -56,8 +56,9 @@
 
 SQUIDCEXTERN int comm_udp_sendto(int sock, const Ip::Address &to, const void *buf, int buflen);
 SQUIDCEXTERN void commCallCloseHandlers(int fd);
-SQUIDCEXTERN int commSetTimeout(int fd, int, CTCB *, void *);
-extern int commSetTimeout(int fd, int, AsyncCall::Pointer &callback);
+
+/// clear a timeout handler by FD number
+extern void commUnsetFdTimeout(int fd);
 
 /**
  * Set or clear the timeout for some action on an active connection.
diff -u -r -N squid-3.2.0.14/src/CommonPool.h squid-3.2.0.15/src/CommonPool.h
--- squid-3.2.0.14/src/CommonPool.h	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/CommonPool.h	2012-02-06 04:52:31.000000000 +1300
@@ -39,7 +39,7 @@
 #define COMMONPOOL_H
 
 #if USE_DELAY_POOLS
-#include "squid.h"
+#include "squid-old.h"
 #include "SquidString.h"
 #include "CompositePoolNode.h"
 
diff -u -r -N squid-3.2.0.14/src/CommRead.h squid-3.2.0.15/src/CommRead.h
--- squid-3.2.0.14/src/CommRead.h	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/CommRead.h	2012-02-06 04:52:31.000000000 +1300
@@ -36,7 +36,7 @@
 #ifndef COMMREAD_H
 #define COMMREAD_H
 
-#include "squid.h"
+#include "squid-old.h"
 #include "comm.h"
 #include "CommCalls.h"
 #include "comm/forward.h"
diff -u -r -N squid-3.2.0.14/src/CompletionDispatcher.cc squid-3.2.0.15/src/CompletionDispatcher.cc
--- squid-3.2.0.14/src/CompletionDispatcher.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/CompletionDispatcher.cc	2012-02-06 04:52:31.000000000 +1300
@@ -31,5 +31,5 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 #include "CompletionDispatcher.h"
diff -u -r -N squid-3.2.0.14/src/CompletionDispatcher.h squid-3.2.0.15/src/CompletionDispatcher.h
--- squid-3.2.0.14/src/CompletionDispatcher.h	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/CompletionDispatcher.h	2012-02-06 04:52:31.000000000 +1300
@@ -34,7 +34,7 @@
 #ifndef SQUID_COMPLETIONDISPATCHER_H
 #define SQUID_COMPLETIONDISPATCHER_H
 
-#include "squid.h"
+#include "squid-old.h"
 
 
 /* Dispatch code to handle events that have completed. Completed events are queued
diff -u -r -N squid-3.2.0.14/src/CompositePoolNode.h squid-3.2.0.15/src/CompositePoolNode.h
--- squid-3.2.0.14/src/CompositePoolNode.h	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/CompositePoolNode.h	2012-02-06 04:52:31.000000000 +1300
@@ -37,7 +37,7 @@
 #define COMPOSITEPOOLNODE_H
 
 #if USE_DELAY_POOLS
-#include "squid.h"
+#include "squid-old.h"
 #include "auth/UserRequest.h"
 #include "DelayPools.h"
 #include "DelayIdComposite.h"
@@ -74,7 +74,7 @@
 
         Ip::Address src_addr;
 #if USE_AUTH
-        AuthUserRequest::Pointer user;
+        Auth::UserRequest::Pointer user;
 #endif
         String tag;
     };
diff -u -r -N squid-3.2.0.14/src/ConfigOption.cc squid-3.2.0.15/src/ConfigOption.cc
--- squid-3.2.0.14/src/ConfigOption.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/ConfigOption.cc	2012-02-06 04:52:31.000000000 +1300
@@ -32,7 +32,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "ConfigOption.h"
 
 ConfigOptionVector::~ConfigOptionVector()
diff -u -r -N squid-3.2.0.14/src/ConfigParser.cc squid-3.2.0.15/src/ConfigParser.cc
--- squid-3.2.0.14/src/ConfigParser.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/ConfigParser.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
  * Copyright (c) 2003, Robert Collins <robertc@squid-cache.org>
  */
 
-#include "config.h"
+#include "squid.h"
 #include "ConfigParser.h"
 #include "globals.h"
 
diff -u -r -N squid-3.2.0.14/src/ConfigParser.h squid-3.2.0.15/src/ConfigParser.h
--- squid-3.2.0.14/src/ConfigParser.h	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/ConfigParser.h	2012-02-06 04:52:31.000000000 +1300
@@ -36,7 +36,7 @@
 #ifndef SQUID_CONFIGPARSER_H
 #define SQUID_CONFIGPARSER_H
 
-#include "squid.h"
+#include "squid-old.h"
 
 /**
  * Limit to how long any given config line may be.
diff -u -r -N squid-3.2.0.14/src/CpuAffinity.cc squid-3.2.0.15/src/CpuAffinity.cc
--- squid-3.2.0.14/src/CpuAffinity.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/CpuAffinity.cc	2012-02-06 04:52:31.000000000 +1300
@@ -5,7 +5,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 #include "base/TextException.h"
 #include "CpuAffinity.h"
 #include "CpuAffinityMap.h"
diff -u -r -N squid-3.2.0.14/src/CpuAffinityMap.cc squid-3.2.0.15/src/CpuAffinityMap.cc
--- squid-3.2.0.14/src/CpuAffinityMap.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/CpuAffinityMap.cc	2012-02-06 04:52:31.000000000 +1300
@@ -5,7 +5,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 #include "base/TextException.h"
 #include "CpuAffinityMap.h"
 #include "CpuAffinitySet.h"
diff -u -r -N squid-3.2.0.14/src/CpuAffinitySet.cc squid-3.2.0.15/src/CpuAffinitySet.cc
--- squid-3.2.0.14/src/CpuAffinitySet.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/CpuAffinitySet.cc	2012-02-06 04:52:31.000000000 +1300
@@ -5,7 +5,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 #include "base/TextException.h"
 #include "CpuAffinitySet.h"
 #include "Debug.h"
diff -u -r -N squid-3.2.0.14/src/debug.cc squid-3.2.0.15/src/debug.cc
--- squid-3.2.0.14/src/debug.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/debug.cc	2012-02-06 04:52:31.000000000 +1300
@@ -32,7 +32,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 #include "Debug.h"
 #include "SquidTime.h"
 #include "util.h"
diff -u -r -N squid-3.2.0.14/src/DelayBucket.cc squid-3.2.0.15/src/DelayBucket.cc
--- squid-3.2.0.14/src/DelayBucket.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/DelayBucket.cc	2012-02-06 04:52:31.000000000 +1300
@@ -36,10 +36,10 @@
  * Copyright (c) 2003, Robert Collins <robertc@squid-cache.org>
  */
 
-#include "config.h"
+#include "squid.h"
 
 #if USE_DELAY_POOLS
-#include "squid.h"
+#include "squid-old.h"
 #include "DelayBucket.h"
 #include "DelaySpec.h"
 #include "Store.h"
diff -u -r -N squid-3.2.0.14/src/DelayConfig.cc squid-3.2.0.15/src/DelayConfig.cc
--- squid-3.2.0.14/src/DelayConfig.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/DelayConfig.cc	2012-02-06 04:52:31.000000000 +1300
@@ -37,10 +37,10 @@
  * Copyright (c) 2003, Robert Collins <robertc@squid-cache.org>
  */
 
-#include "config.h"
+#include "squid.h"
 
 #if USE_DELAY_POOLS
-#include "squid.h"
+#include "squid-old.h"
 #include "DelayConfig.h"
 #include "ConfigParser.h"
 #include "DelayPools.h"
diff -u -r -N squid-3.2.0.14/src/DelayId.cc squid-3.2.0.15/src/DelayId.cc
--- squid-3.2.0.14/src/DelayId.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/DelayId.cc	2012-02-06 04:52:31.000000000 +1300
@@ -37,14 +37,14 @@
  * Copyright (c) 2003, Robert Collins <robertc@squid-cache.org>
  */
 
-#include "config.h"
+#include "squid.h"
 
 /* MS Visual Studio Projects are monolithic, so we need the following
  * #if to exclude the delay pools code from compile process when not needed.
  */
 #if USE_DELAY_POOLS
 
-#include "squid.h"
+#include "squid-old.h"
 #include "DelayId.h"
 #include "client_side_request.h"
 #include "acl/FilledChecklist.h"
diff -u -r -N squid-3.2.0.14/src/DelayIdComposite.h squid-3.2.0.15/src/DelayIdComposite.h
--- squid-3.2.0.14/src/DelayIdComposite.h	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/DelayIdComposite.h	2012-02-06 04:52:31.000000000 +1300
@@ -40,7 +40,7 @@
 #define DELAYIDCOMPOSITE_H
 
 #if USE_DELAY_POOLS
-#include "squid.h"
+#include "squid-old.h"
 #include "RefCount.h"
 
 class DeferredRead;
diff -u -r -N squid-3.2.0.14/src/DelayPool.cc squid-3.2.0.15/src/DelayPool.cc
--- squid-3.2.0.14/src/DelayPool.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/DelayPool.cc	2012-02-06 04:52:31.000000000 +1300
@@ -36,7 +36,7 @@
  * Copyright (c) 2003, Robert Collins <robertc@squid-cache.org>
  */
 
-#include "config.h"
+#include "squid.h"
 
 #if USE_DELAY_POOLS
 #include "DelayPool.h"
diff -u -r -N squid-3.2.0.14/src/DelayPool.h squid-3.2.0.15/src/DelayPool.h
--- squid-3.2.0.14/src/DelayPool.h	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/DelayPool.h	2012-02-06 04:52:31.000000000 +1300
@@ -40,7 +40,7 @@
 #define DELAYPOOL_H
 
 #if USE_DELAY_POOLS
-#include "squid.h"
+#include "squid-old.h"
 #include "CompositePoolNode.h"
 
 class StoreEntry;
diff -u -r -N squid-3.2.0.14/src/delay_pools.cc squid-3.2.0.15/src/delay_pools.cc
--- squid-3.2.0.14/src/delay_pools.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/delay_pools.cc	2012-02-06 04:52:31.000000000 +1300
@@ -39,10 +39,10 @@
  \ingroup DelayPoolsAPI
  */
 
-#include "config.h"
+#include "squid.h"
 
 #if USE_DELAY_POOLS
-#include "squid.h"
+#include "squid-old.h"
 #include "mgr/Registration.h"
 #include "DelaySpec.h"
 #include "DelayPools.h"
diff -u -r -N squid-3.2.0.14/src/DelaySpec.cc squid-3.2.0.15/src/DelaySpec.cc
--- squid-3.2.0.14/src/DelaySpec.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/DelaySpec.cc	2012-02-06 04:52:31.000000000 +1300
@@ -37,10 +37,10 @@
  * Copyright (c) 2003, Robert Collins <robertc@squid-cache.org>
  */
 
-#include "config.h"
+#include "squid.h"
 
 #if USE_DELAY_POOLS
-#include "squid.h"
+#include "squid-old.h"
 #include "DelaySpec.h"
 #include "Store.h"
 #include "Parsing.h"
diff -u -r -N squid-3.2.0.14/src/DelayTagged.cc squid-3.2.0.15/src/DelayTagged.cc
--- squid-3.2.0.14/src/DelayTagged.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/DelayTagged.cc	2012-02-06 04:52:31.000000000 +1300
@@ -35,10 +35,10 @@
  * Copyright (c) 2003, Robert Collins <robertc@squid-cache.org>
  */
 
-#include "config.h"
+#include "squid.h"
 
 #if USE_DELAY_POOLS
-#include "squid.h"
+#include "squid-old.h"
 #include "comm/Connection.h"
 #include "DelayTagged.h"
 #include "NullDelayId.h"
diff -u -r -N squid-3.2.0.14/src/DelayTagged.h squid-3.2.0.15/src/DelayTagged.h
--- squid-3.2.0.14/src/DelayTagged.h	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/DelayTagged.h	2012-02-06 04:52:31.000000000 +1300
@@ -38,7 +38,7 @@
 
 #if USE_DELAY_POOLS
 
-#include "squid.h"
+#include "squid-old.h"
 #include "auth/Gadgets.h"
 #include "CompositePoolNode.h"
 #include "DelayIdComposite.h"
diff -u -r -N squid-3.2.0.14/src/DelayUser.cc squid-3.2.0.15/src/DelayUser.cc
--- squid-3.2.0.14/src/DelayUser.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/DelayUser.cc	2012-02-06 04:52:31.000000000 +1300
@@ -35,10 +35,10 @@
  * Copyright (c) 2003, Robert Collins <robertc@squid-cache.org>
  */
 
-#include "config.h"
+#include "squid.h"
 
 #if USE_DELAY_POOLS && USE_AUTH
-#include "squid.h"
+#include "squid-old.h"
 #include "DelayUser.h"
 #include "auth/UserRequest.h"
 #include "auth/User.h"
diff -u -r -N squid-3.2.0.14/src/DelayUser.h squid-3.2.0.15/src/DelayUser.h
--- squid-3.2.0.14/src/DelayUser.h	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/DelayUser.h	2012-02-06 04:52:31.000000000 +1300
@@ -38,7 +38,7 @@
 
 #if USE_DELAY_POOLS && USE_AUTH
 
-#include "squid.h"
+#include "squid-old.h"
 #include "auth/Gadgets.h"
 #include "auth/User.h"
 #include "CompositePoolNode.h"
diff -u -r -N squid-3.2.0.14/src/DelayVector.cc squid-3.2.0.15/src/DelayVector.cc
--- squid-3.2.0.14/src/DelayVector.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/DelayVector.cc	2012-02-06 04:52:31.000000000 +1300
@@ -37,10 +37,10 @@
  * Copyright (c) 2003, Robert Collins <robertc@squid-cache.org>
  */
 
-#include "config.h"
+#include "squid.h"
 
 #if USE_DELAY_POOLS
-#include "squid.h"
+#include "squid-old.h"
 #include "comm/Connection.h"
 #include "DelayVector.h"
 #include "CommRead.h"
diff -u -r -N squid-3.2.0.14/src/DescriptorSet.cc squid-3.2.0.15/src/DescriptorSet.cc
--- squid-3.2.0.14/src/DescriptorSet.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/DescriptorSet.cc	2012-02-06 04:52:31.000000000 +1300
@@ -3,7 +3,7 @@
  *
  * DEBUG: section 05    Comm
  */
-#include "config.h"
+#include "squid.h"
 #include "DescriptorSet.h"
 
 // pre-allocates descriptor store and index for Squid_MaxFD descriptors
diff -u -r -N squid-3.2.0.14/src/DescriptorSet.h squid-3.2.0.15/src/DescriptorSet.h
--- squid-3.2.0.14/src/DescriptorSet.h	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/DescriptorSet.h	2012-02-06 04:52:31.000000000 +1300
@@ -1,7 +1,7 @@
 #ifndef SQUID_DESCRIPTOR_SET_H
 #define SQUID_DESCRIPTOR_SET_H
 
-#include "squid.h"
+#include "squid-old.h"
 
 /** \ingroup Comm
 
diff -u -r -N squid-3.2.0.14/src/disk.cc squid-3.2.0.15/src/disk.cc
--- squid-3.2.0.14/src/disk.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/disk.cc	2012-02-06 04:52:31.000000000 +1300
@@ -32,7 +32,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "comm/Loops.h"
 #include "fde.h"
 #include "MemBuf.h"
diff -u -r -N squid-3.2.0.14/src/DiskIO/AIO/AIODiskFile.cc squid-3.2.0.15/src/DiskIO/AIO/AIODiskFile.cc
--- squid-3.2.0.14/src/DiskIO/AIO/AIODiskFile.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/DiskIO/AIO/AIODiskFile.cc	2012-02-06 04:52:31.000000000 +1300
@@ -44,7 +44,7 @@
  * per storedir it should work just fine.
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "AIODiskFile.h"
 #include "AIODiskIOStrategy.h"
 #include "DiskIO/IORequestor.h"
diff -u -r -N squid-3.2.0.14/src/DiskIO/AIO/AIODiskIOModule.cc squid-3.2.0.15/src/DiskIO/AIO/AIODiskIOModule.cc
--- squid-3.2.0.14/src/DiskIO/AIO/AIODiskIOModule.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/DiskIO/AIO/AIODiskIOModule.cc	2012-02-06 04:52:31.000000000 +1300
@@ -31,7 +31,7 @@
  * Copyright (c) 2003, Robert Collins <robertc@squid-cache.org>
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "AIODiskIOModule.h"
 #include "AIODiskIOStrategy.h"
 #include "Store.h"
diff -u -r -N squid-3.2.0.14/src/DiskIO/AIO/AIODiskIOStrategy.cc squid-3.2.0.15/src/DiskIO/AIO/AIODiskIOStrategy.cc
--- squid-3.2.0.14/src/DiskIO/AIO/AIODiskIOStrategy.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/DiskIO/AIO/AIODiskIOStrategy.cc	2012-02-06 04:52:31.000000000 +1300
@@ -42,7 +42,7 @@
  * per storedir it should work just fine.
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "AIODiskIOStrategy.h"
 #include "AIODiskFile.h"
 #include "DiskIO/IORequestor.h"
diff -u -r -N squid-3.2.0.14/src/DiskIO/AIO/aio_win32.cc squid-3.2.0.15/src/DiskIO/AIO/aio_win32.cc
--- squid-3.2.0.14/src/DiskIO/AIO/aio_win32.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/DiskIO/AIO/aio_win32.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "comm.h"
 #include "aio_win32.h"
 
diff -u -r -N squid-3.2.0.14/src/DiskIO/Blocking/BlockingDiskIOModule.cc squid-3.2.0.15/src/DiskIO/Blocking/BlockingDiskIOModule.cc
--- squid-3.2.0.14/src/DiskIO/Blocking/BlockingDiskIOModule.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/DiskIO/Blocking/BlockingDiskIOModule.cc	2012-02-06 04:52:31.000000000 +1300
@@ -31,7 +31,7 @@
  * Copyright (c) 2003, Robert Collins <robertc@squid-cache.org>
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "BlockingDiskIOModule.h"
 #include "BlockingIOStrategy.h"
 
diff -u -r -N squid-3.2.0.14/src/DiskIO/Blocking/BlockingFile.cc squid-3.2.0.15/src/DiskIO/Blocking/BlockingFile.cc
--- squid-3.2.0.14/src/DiskIO/Blocking/BlockingFile.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/DiskIO/Blocking/BlockingFile.cc	2012-02-06 04:52:31.000000000 +1300
@@ -32,7 +32,7 @@
  *
  * Copyright (c) 2003, Robert Collins <robertc@squid-cache.org>
  */
-#include "config.h"
+#include "squid.h"
 #include "BlockingFile.h"
 #include "DiskIO/IORequestor.h"
 #include "DiskIO/ReadRequest.h"
diff -u -r -N squid-3.2.0.14/src/DiskIO/Blocking/BlockingIOStrategy.cc squid-3.2.0.15/src/DiskIO/Blocking/BlockingIOStrategy.cc
--- squid-3.2.0.14/src/DiskIO/Blocking/BlockingIOStrategy.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/DiskIO/Blocking/BlockingIOStrategy.cc	2012-02-06 04:52:31.000000000 +1300
@@ -34,7 +34,7 @@
  * Copyright (c) 2003, Robert Collins <robertc@squid-cache.org>
  */
 
-#include "config.h"
+#include "squid.h"
 #include "BlockingIOStrategy.h"
 #include "BlockingFile.h"
 
diff -u -r -N squid-3.2.0.14/src/DiskIO/DiskDaemon/DiskdAction.cc squid-3.2.0.15/src/DiskIO/DiskDaemon/DiskdAction.cc
--- squid-3.2.0.14/src/DiskIO/DiskDaemon/DiskdAction.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/DiskIO/DiskDaemon/DiskdAction.cc	2012-02-06 04:52:31.000000000 +1300
@@ -5,7 +5,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 #include "base/TextException.h"
 #include "Store.h"
 #include "ipc/Messages.h"
diff -u -r -N squid-3.2.0.14/src/DiskIO/DiskDaemon/DiskDaemonDiskIOModule.cc squid-3.2.0.15/src/DiskIO/DiskDaemon/DiskDaemonDiskIOModule.cc
--- squid-3.2.0.14/src/DiskIO/DiskDaemon/DiskDaemonDiskIOModule.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/DiskIO/DiskDaemon/DiskDaemonDiskIOModule.cc	2012-02-06 04:52:31.000000000 +1300
@@ -31,7 +31,7 @@
  * Copyright (c) 2003, Robert Collins <robertc@squid-cache.org>
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "DiskDaemonDiskIOModule.h"
 #include "DiskdIOStrategy.h"
 #include "DiskIO/DiskDaemon/DiskdAction.h"
diff -u -r -N squid-3.2.0.14/src/DiskIO/DiskDaemon/diskd.cc squid-3.2.0.15/src/DiskIO/DiskDaemon/diskd.cc
--- squid-3.2.0.14/src/DiskIO/DiskDaemon/diskd.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/DiskIO/DiskDaemon/diskd.cc	2012-02-06 04:52:31.000000000 +1300
@@ -32,14 +32,19 @@
  *
  */
 
-#include "config.h"
 #include "squid.h"
+#include "DiskIO/DiskDaemon/diomsg.h"
+#include "hash.h"
 
+#if HAVE_ERRNO_H
+#include <errno.h>
+#endif
 #include <sys/ipc.h>
 #include <sys/msg.h>
 #include <sys/shm.h>
-
-#include "DiskIO/DiskDaemon/diomsg.h"
+#if HAVE_IOSTREAM
+#include <iostream>
+#endif
 
 void
 xassert(const char *msg, const char *file, int line)
diff -u -r -N squid-3.2.0.14/src/DiskIO/DiskDaemon/DiskdFile.cc squid-3.2.0.15/src/DiskIO/DiskDaemon/DiskdFile.cc
--- squid-3.2.0.14/src/DiskIO/DiskDaemon/DiskdFile.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/DiskIO/DiskDaemon/DiskdFile.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
  * CopyRight (c) 2003, Robert Collins <robertc@squid-cache.org>
  */
 
-#include "squid.h"
+#include "squid-old.h"
 
 #include <sys/ipc.h>
 #include <sys/msg.h>
diff -u -r -N squid-3.2.0.14/src/DiskIO/DiskDaemon/DiskdIOStrategy.cc squid-3.2.0.15/src/DiskIO/DiskDaemon/DiskdIOStrategy.cc
--- squid-3.2.0.14/src/DiskIO/DiskDaemon/DiskdIOStrategy.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/DiskIO/DiskDaemon/DiskdIOStrategy.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
  * Copyright (c) 2003, Robert Collins <robertc@squid-cache.org>
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "comm/Loops.h"
 
 #include <sys/ipc.h>
@@ -209,7 +209,7 @@
 
     fd_note(wfd, "squid -> diskd");
 
-    commSetTimeout(wfd, -1, NULL, NULL);
+    commUnsetFdTimeout(wfd);
     commSetNonBlocking(wfd);
     Comm::QuickPollRequired();
 }
diff -u -r -N squid-3.2.0.14/src/DiskIO/DiskFile.h squid-3.2.0.15/src/DiskIO/DiskFile.h
--- squid-3.2.0.14/src/DiskIO/DiskFile.h	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/DiskIO/DiskFile.h	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
 #ifndef SQUID_DISKFILE_H
 #define SQUID_DISKFILE_H
 
-#include "squid.h"
+#include "squid-old.h"
 
 #include "RefCount.h"
 
diff -u -r -N squid-3.2.0.14/src/DiskIO/DiskIOModule.cc squid-3.2.0.15/src/DiskIO/DiskIOModule.cc
--- squid-3.2.0.14/src/DiskIO/DiskIOModule.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/DiskIO/DiskIOModule.cc	2012-02-06 04:52:31.000000000 +1300
@@ -32,7 +32,7 @@
  * Copyright (c) 2003, Robert Collins <robertc@squid-cache.org>
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "DiskIOModule.h"
 
 Vector<DiskIOModule*> *DiskIOModule::_Modules = NULL;
diff -u -r -N squid-3.2.0.14/src/DiskIO/DiskIOModule.h squid-3.2.0.15/src/DiskIO/DiskIOModule.h
--- squid-3.2.0.14/src/DiskIO/DiskIOModule.h	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/DiskIO/DiskIOModule.h	2012-02-06 04:52:31.000000000 +1300
@@ -34,7 +34,7 @@
 #ifndef SQUID_DISKIOMODULE_H
 #define SQUID_DISKIOMODULE_H
 
-#include "squid.h"
+#include "squid-old.h"
 #include "Array.h"
 
 /* forward decls */
diff -u -r -N squid-3.2.0.14/src/DiskIO/DiskIOStrategy.h squid-3.2.0.15/src/DiskIO/DiskIOStrategy.h
--- squid-3.2.0.14/src/DiskIO/DiskIOStrategy.h	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/DiskIO/DiskIOStrategy.h	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
 #ifndef SQUID_DISKIOSTRATEGY_H
 #define SQUID_DISKIOSTRATEGY_H
 
-#include "squid.h"
+#include "squid-old.h"
 
 #include "RefCount.h"
 
diff -u -r -N squid-3.2.0.14/src/DiskIO/DiskThreads/aiops.cc squid-3.2.0.15/src/DiskIO/DiskThreads/aiops.cc
--- squid-3.2.0.14/src/DiskIO/DiskThreads/aiops.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/DiskIO/DiskThreads/aiops.cc	2012-02-06 04:52:31.000000000 +1300
@@ -36,7 +36,7 @@
 #error "_REENTRANT MUST be defined to build squid async io support."
 #endif
 
-#include "squid.h"
+#include "squid-old.h"
 #include "DiskThreads.h"
 
 #include	<stdio.h>
diff -u -r -N squid-3.2.0.14/src/DiskIO/DiskThreads/aiops_win32.cc squid-3.2.0.15/src/DiskIO/DiskThreads/aiops_win32.cc
--- squid-3.2.0.14/src/DiskIO/DiskThreads/aiops_win32.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/DiskIO/DiskThreads/aiops_win32.cc	2012-02-06 04:52:31.000000000 +1300
@@ -34,7 +34,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "squid_windows.h"
 #include "CommIO.h"
 #include "DiskThreads.h"
diff -u -r -N squid-3.2.0.14/src/DiskIO/DiskThreads/async_io.cc squid-3.2.0.15/src/DiskIO/DiskThreads/async_io.cc
--- squid-3.2.0.14/src/DiskIO/DiskThreads/async_io.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/DiskIO/DiskThreads/async_io.cc	2012-02-06 04:52:31.000000000 +1300
@@ -34,7 +34,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "DiskThreads.h"
 #include "Store.h"
 #include "fde.h"
diff -u -r -N squid-3.2.0.14/src/DiskIO/DiskThreads/DiskThreadsDiskFile.cc squid-3.2.0.15/src/DiskIO/DiskThreads/DiskThreadsDiskFile.cc
--- squid-3.2.0.14/src/DiskIO/DiskThreads/DiskThreadsDiskFile.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/DiskIO/DiskThreads/DiskThreadsDiskFile.cc	2012-02-06 04:52:31.000000000 +1300
@@ -34,7 +34,7 @@
  */
 
 
-#include "squid.h"
+#include "squid-old.h"
 #include "DiskThreadsDiskFile.h"
 #include "Store.h"
 #include "Generic.h"
diff -u -r -N squid-3.2.0.14/src/DiskIO/DiskThreads/DiskThreadsDiskIOModule.cc squid-3.2.0.15/src/DiskIO/DiskThreads/DiskThreadsDiskIOModule.cc
--- squid-3.2.0.14/src/DiskIO/DiskThreads/DiskThreadsDiskIOModule.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/DiskIO/DiskThreads/DiskThreadsDiskIOModule.cc	2012-02-06 04:52:31.000000000 +1300
@@ -31,7 +31,7 @@
  * Copyright (c) 2003, Robert Collins <robertc@squid-cache.org>
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "DiskThreadsDiskIOModule.h"
 #include "DiskThreadsIOStrategy.h"
 
diff -u -r -N squid-3.2.0.14/src/DiskIO/DiskThreads/DiskThreadsIOStrategy.cc squid-3.2.0.15/src/DiskIO/DiskThreads/DiskThreadsIOStrategy.cc
--- squid-3.2.0.14/src/DiskIO/DiskThreads/DiskThreadsIOStrategy.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/DiskIO/DiskThreads/DiskThreadsIOStrategy.cc	2012-02-06 04:52:31.000000000 +1300
@@ -34,7 +34,7 @@
  * Copyright (c) 2003, Robert Collins <robertc@squid-cache.org>
  */
 
-#include "squid.h"
+#include "squid-old.h"
 
 #include "DiskThreadsDiskFile.h"
 #include "DiskThreadsIOStrategy.h"
diff -u -r -N squid-3.2.0.14/src/DiskIO/IORequestor.h squid-3.2.0.15/src/DiskIO/IORequestor.h
--- squid-3.2.0.14/src/DiskIO/IORequestor.h	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/DiskIO/IORequestor.h	2012-02-06 04:52:31.000000000 +1300
@@ -34,7 +34,7 @@
 #ifndef SQUID_IOREQUESTOR_H
 #define SQUID_IOREQUESTOR_H
 
-#include "squid.h"
+#include "squid-old.h"
 
 #include "RefCount.h"
 
diff -u -r -N squid-3.2.0.14/src/DiskIO/IpcIo/IpcIoDiskIOModule.cc squid-3.2.0.15/src/DiskIO/IpcIo/IpcIoDiskIOModule.cc
--- squid-3.2.0.14/src/DiskIO/IpcIo/IpcIoDiskIOModule.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/DiskIO/IpcIo/IpcIoDiskIOModule.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "squid.h"
+#include "squid-old.h"
 #include "IpcIoDiskIOModule.h"
 #include "IpcIoIOStrategy.h"
 
diff -u -r -N squid-3.2.0.14/src/DiskIO/IpcIo/IpcIoFile.cc squid-3.2.0.15/src/DiskIO/IpcIo/IpcIoFile.cc
--- squid-3.2.0.14/src/DiskIO/IpcIo/IpcIoFile.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/DiskIO/IpcIo/IpcIoFile.cc	2012-02-06 04:52:31.000000000 +1300
@@ -4,7 +4,7 @@
  * DEBUG: section 47    Store Directory Routines
  */
 
-#include "config.h"
+#include "squid.h"
 #include "base/RunnersRegistry.h"
 #include "base/TextException.h"
 #include "DiskIO/IORequestor.h"
diff -u -r -N squid-3.2.0.14/src/DiskIO/IpcIo/IpcIoIOStrategy.cc squid-3.2.0.15/src/DiskIO/IpcIo/IpcIoIOStrategy.cc
--- squid-3.2.0.14/src/DiskIO/IpcIo/IpcIoIOStrategy.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/DiskIO/IpcIo/IpcIoIOStrategy.cc	2012-02-06 04:52:31.000000000 +1300
@@ -5,7 +5,7 @@
  * DEBUG: section 47    Store Directory Routines
  */
 
-#include "config.h"
+#include "squid.h"
 #include "IpcIoFile.h"
 #include "IpcIoIOStrategy.h"
 
diff -u -r -N squid-3.2.0.14/src/DiskIO/Mmapped/MmappedDiskIOModule.cc squid-3.2.0.15/src/DiskIO/Mmapped/MmappedDiskIOModule.cc
--- squid-3.2.0.14/src/DiskIO/Mmapped/MmappedDiskIOModule.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/DiskIO/Mmapped/MmappedDiskIOModule.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "squid.h"
+#include "squid-old.h"
 #include "MmappedDiskIOModule.h"
 #include "MmappedIOStrategy.h"
 
diff -u -r -N squid-3.2.0.14/src/DiskIO/Mmapped/MmappedFile.cc squid-3.2.0.15/src/DiskIO/Mmapped/MmappedFile.cc
--- squid-3.2.0.14/src/DiskIO/Mmapped/MmappedFile.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/DiskIO/Mmapped/MmappedFile.cc	2012-02-06 04:52:31.000000000 +1300
@@ -4,7 +4,7 @@
  * DEBUG: section 47    Store Directory Routines
  */
 
-#include "config.h"
+#include "squid.h"
 #include "DiskIO/IORequestor.h"
 #include "DiskIO/Mmapped/MmappedFile.h"
 #include "DiskIO/ReadRequest.h"
diff -u -r -N squid-3.2.0.14/src/DiskIO/Mmapped/MmappedIOStrategy.cc squid-3.2.0.15/src/DiskIO/Mmapped/MmappedIOStrategy.cc
--- squid-3.2.0.14/src/DiskIO/Mmapped/MmappedIOStrategy.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/DiskIO/Mmapped/MmappedIOStrategy.cc	2012-02-06 04:52:31.000000000 +1300
@@ -5,7 +5,7 @@
  * DEBUG: section 47    Store Directory Routines
  */
 
-#include "config.h"
+#include "squid.h"
 #include "MmappedFile.h"
 #include "MmappedIOStrategy.h"
 
diff -u -r -N squid-3.2.0.14/src/DiskIO/ReadRequest.cc squid-3.2.0.15/src/DiskIO/ReadRequest.cc
--- squid-3.2.0.14/src/DiskIO/ReadRequest.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/DiskIO/ReadRequest.cc	2012-02-06 04:52:31.000000000 +1300
@@ -31,7 +31,7 @@
  * Copyright (c) 2003 Robert Collins <robertc@squid-cache.org>
  */
 
-#include "config.h"
+#include "squid.h"
 #include "ReadRequest.h"
 
 CBDATA_CLASS_INIT(ReadRequest);
diff -u -r -N squid-3.2.0.14/src/DiskIO/ReadRequest.h squid-3.2.0.15/src/DiskIO/ReadRequest.h
--- squid-3.2.0.14/src/DiskIO/ReadRequest.h	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/DiskIO/ReadRequest.h	2012-02-06 04:52:31.000000000 +1300
@@ -34,7 +34,7 @@
 #ifndef SQUID_READREQUEST_H
 #define SQUID_READREQUEST_H
 
-#include "squid.h"
+#include "squid-old.h"
 
 #include "cbdata.h"
 #include "RefCount.h"
diff -u -r -N squid-3.2.0.14/src/DiskIO/WriteRequest.cc squid-3.2.0.15/src/DiskIO/WriteRequest.cc
--- squid-3.2.0.14/src/DiskIO/WriteRequest.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/DiskIO/WriteRequest.cc	2012-02-06 04:52:31.000000000 +1300
@@ -31,7 +31,7 @@
  * Copyright (c) 2003 Robert Collins <robertc@squid-cache.org>
  */
 
-#include "config.h"
+#include "squid.h"
 #include "WriteRequest.h"
 
 CBDATA_CLASS_INIT(WriteRequest);
diff -u -r -N squid-3.2.0.14/src/DiskIO/WriteRequest.h squid-3.2.0.15/src/DiskIO/WriteRequest.h
--- squid-3.2.0.14/src/DiskIO/WriteRequest.h	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/DiskIO/WriteRequest.h	2012-02-06 04:52:31.000000000 +1300
@@ -34,7 +34,7 @@
 #ifndef SQUID_WRITEREQUEST_H
 #define SQUID_WRITEREQUEST_H
 
-#include "squid.h"
+#include "squid-old.h"
 
 #include "cbdata.h"
 #include "RefCount.h"
diff -u -r -N squid-3.2.0.14/src/dlink.cc squid-3.2.0.15/src/dlink.cc
--- squid-3.2.0.14/src/dlink.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/dlink.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,7 +1,7 @@
 /*
  * $Id$
  */
-#include "config.h"
+#include "squid.h"
 #include "dlink.h"
 
 /* dlink are Mem-pooled */
diff -u -r -N squid-3.2.0.14/src/dns.cc squid-3.2.0.15/src/dns.cc
--- squid-3.2.0.14/src/dns.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/dns.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "Store.h"
 #include "wordlist.h"
 #include "SquidTime.h"
@@ -44,7 +44,7 @@
    #if to include the external DNS code in compile process when
    using external DNS.
  */
-#if USE_DNSSERVERS
+#if USE_DNSHELPER
 
 static helper *dnsservers = NULL;
 
@@ -180,4 +180,4 @@
 }
 
 #endif /* SQUID_SNMP */
-#endif /* USE_DNSSERVERS */
+#endif /* USE_DNSHELPER */
diff -u -r -N squid-3.2.0.14/src/dns_internal.cc squid-3.2.0.15/src/dns_internal.cc
--- squid-3.2.0.14/src/dns_internal.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/dns_internal.cc	2012-02-06 04:52:31.000000000 +1300
@@ -32,7 +32,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "comm/Connection.h"
 #include "comm/ConnOpener.h"
 #include "comm.h"
@@ -60,7 +60,7 @@
    #ifndef to exclude the internal DNS code from compile process when
    using external DNS process.
  */
-#if !USE_DNSSERVERS
+#if !USE_DNSHELPER
 #if _SQUID_WINDOWS_
 #include "squid_windows.h"
 #define REG_TCPIP_PARA_INTERFACES "SYSTEM\\CurrentControlSet\\Services\\Tcpip\\Parameters\\Interfaces"
@@ -127,11 +127,12 @@
     char name[NS_MAXDNAME + 1];
     char orig[NS_MAXDNAME + 1];
     ssize_t sz;
-    unsigned short msg_id; /// random query ID sent to server; changes with every query sent
+    unsigned short query_id; /// random query ID sent to server; changes with every query sent
     InstanceId<idns_query> xact_id; /// identifies our "transaction", stays constant when query is retried
 
     int nsends;
     int need_vc;
+    int pending;
 
     struct timeval start_t;
     struct timeval sent_t;
@@ -142,13 +143,12 @@
     int attempt;
     int rcode;
     idns_query *queue;
+    idns_query *slave;  // AAAA
+    idns_query *master; // A
     unsigned short domain;
     unsigned short do_searchpath;
-    bool need_A;
-    struct {
-        int count;
-        rfc1035_rr *answers;
-    } initial_AAAA;
+    rfc1035_message *message;
+    int ancount;
 };
 InstanceIdDefinitions(idns_query,  "dns");
 
@@ -249,6 +249,7 @@
 static void idnsRcodeCount(int, int);
 static CLCB idnsVCClosed;
 static unsigned short idnsQueryID(void);
+static void idnsSendSlaveAAAAQuery(idns_query *q);
 
 static void
 idnsAddNameserver(const char *buf)
@@ -670,7 +671,7 @@
     for (n = lru_list.head; n; n = n->next) {
         q = (idns_query *)n->data;
         storeAppendPrintf(sentry, "%#06x %4d %5d %10.3f %9.3f\n",
-                          (int) q->msg_id, (int) q->sz, q->nsends,
+                          (int) q->query_id, (int) q->sz, q->nsends,
                           tvSubDsec(q->start_t, current_time),
                           tvSubDsec(q->sent_t, current_time));
     }
@@ -821,7 +822,7 @@
     delete vc->queue;
     delete vc->msg;
     vc->conn = NULL;
-    if (vc->ns < nns) // XXX: idnsShutdown may have freed nameservers[]
+    if (vc->ns < nns) // XXX: dnsShutdown may have freed nameservers[]
         nameservers[vc->ns].vc = NULL;
     cbdataFree(vc);
 }
@@ -906,8 +907,6 @@
     int ns;
 
     q->start_t = current_time;
-    q->msg_id = idnsQueryID();
-    rfc1035SetQueryID(q->buf, q->msg_id);
 
     do {
         ns = q->nsends % nns;
@@ -918,7 +917,7 @@
         } else {
             if (DnsSocketB >= 0 && nameservers[ns].S.IsIPv6())
                 y = comm_udp_sendto(DnsSocketB, nameservers[ns].S, q->buf, q->sz);
-            else if (DnsSocketA)
+            else if (DnsSocketA >= 0)
                 x = comm_udp_sendto(DnsSocketA, nameservers[ns].S, q->buf, q->sz);
         }
 
@@ -943,6 +942,7 @@
     nameservers[ns].nqueries++;
     q->queue_t = current_time;
     dlinkAdd(q, &q->lru, &lru_list);
+    q->pending = 1;
     idnsTickleQueue();
 }
 
@@ -973,7 +973,7 @@
     for (n = lru_list.tail; n; n = n->prev) {
         q = (idns_query*)n->data;
 
-        if (q->msg_id == id)
+        if (q->query_id == id)
             return q;
     }
 
@@ -1028,16 +1028,6 @@
     }
 }
 
-void
-idnsDropMessage(rfc1035_message *message, idns_query *q)
-{
-    rfc1035MessageDestroy(&message);
-    if (q->hash.key) {
-        hash_remove_link(idns_lookup_hash, &q->hash);
-        q->hash.key = NULL;
-    }
-}
-
 static void
 idnsGrokReply(const char *buf, size_t sz, int from_ns)
 {
@@ -1092,9 +1082,11 @@
     }
 #endif
 
+    dlinkDelete(&q->lru, &lru_list);
+    q->pending = 0;
+
     if (message->tc) {
         debugs(78, 3, HERE << "Resolver requested TC (" << q->query.name << ")");
-        dlinkDelete(&q->lru, &lru_list);
         rfc1035MessageDestroy(&message);
 
         if (!q->need_vc) {
@@ -1112,7 +1104,6 @@
         return;
     }
 
-    dlinkDelete(&q->lru, &lru_list);
     idnsRcodeCount(n, q->attempt);
 
     if (n < 0) {
@@ -1131,7 +1122,7 @@
             return;
         }
 
-        if (q->rcode == 3 && q->do_searchpath && q->attempt < MAX_ATTEMPT) {
+        if (q->rcode == 3 && !q->master && q->do_searchpath && q->attempt < MAX_ATTEMPT) {
             assert(NULL == message->answer);
             strcpy(q->name, q->orig);
 
@@ -1146,17 +1137,21 @@
                 q->attempt++;
             }
 
-            idnsDropMessage(message, q);
+            rfc1035MessageDestroy(&message);
 
-            if (Ip::EnableIpv6 && q->query.qtype == RFC1035_TYPE_AAAA) {
-                debugs(78, 3, "idnsGrokReply: Trying AAAA Query for " << q->name);
-                q->sz = rfc3596BuildAAAAQuery(q->name, q->buf, sizeof(q->buf), 0, &q->query, Config.dns.packet_max);
-            } else {
-                debugs(78, 3, "idnsGrokReply: Trying A Query for " << q->name);
-                // see EDNS notes at top of file why this sends 0
-                q->sz = rfc3596BuildAQuery(q->name, q->buf, sizeof(q->buf), 0, &q->query, 0);
+            // cleanup stale AAAA query
+            while (idns_query *slave = q->slave) {
+                dlinkDelete(&slave->lru, &lru_list);
+                q->slave = slave->slave;
+                rfc1035MessageDestroy(&slave->message);
+                cbdataFree(slave);
             }
 
+            // Build new query
+            q->query_id = idnsQueryID();
+            debugs(78, 3, "idnsGrokReply: Trying A Query for " << q->name);
+            // see EDNS notes at top of file why this sends 0
+            q->sz = rfc3596BuildAQuery(q->name, q->buf, sizeof(q->buf), q->query_id, &q->query, 0);
             if (q->sz < 0) {
                 /* problem with query data -- query not sent */
                 idnsCallback(static_cast<idns_query *>(q->callback_data), NULL, 0, "Internal error");
@@ -1164,94 +1159,62 @@
                 return;
             }
 
-            idnsCacheQuery(q);
             idnsSendQuery(q);
+            if (Ip::EnableIpv6)
+                idnsSendSlaveAAAAQuery(q);
             return;
         }
     }
 
-    if (q->need_A && (Config.onoff.dns_require_A == 1 || n <= 0 ) ) {
-        /* ERROR or NO AAAA exist. Failover to A records. */
-        /*      Apparently its also a good idea to lookup and store the A records
-         *      just in case the AAAA are not available when we need them.
-         *      This could occur due to number of network failings beyond our control
-         *      thus the || above allowing the user to request always both.
-         */
+    q->message = message;
+    q->ancount = n;
 
-        if (n == 0)
-            debugs(78, 3, "idnsGrokReply: " << q->name << " has no AAAA records. Looking up A record instead.");
-        else if (q->need_A && n <= 0)
-            debugs(78, 3, "idnsGrokReply: " << q->name << " AAAA query failed. Trying A now instead.");
-        else // admin requested this.
-            debugs(78, 3, "idnsGrokReply: " << q->name << " AAAA query done. Configured to retrieve A now also.");
-
-        // move the initial message results into the failover query for merging later.
-        if (n > 0) {
-            q->initial_AAAA.count = message->ancount;
-            q->initial_AAAA.answers = message->answer;
-            message->answer = NULL;
-        }
+    if (q->master)
+        q = q->master;
 
-        // remove the hashed query info
-        idnsDropMessage(message, q);
-
-        // reset the query as an A query
-        q->nsends = 0;
-        // see EDNS notes at top of file why this sends 0
-        q->sz = rfc3596BuildAQuery(q->name, q->buf, sizeof(q->buf), 0, &q->query, 0);
-        q->need_A = false;
-
-        if (q->sz < 0) {
-            /* problem with query data -- query not sent */
-            idnsCallback(static_cast<idns_query *>(q->callback_data), NULL, 0, "Internal error");
-            cbdataFree(q);
+    idns_query *q2;
+    // If any of our subqueries are still pending then wait for them to complete before continuing
+    for ( q2 = q; q2; q2 = q2->slave) {
+        if (q2->pending) {
             return;
         }
-
-        idnsCacheQuery(q);
-        idnsSendQuery(q);
-        return;
     }
 
-    /** If there are two result sets from preceeding AAAA and A lookups merge them with a preference for AAAA */
-    if (q->initial_AAAA.count > 0 && n > 0) {
-        /* two sets of RR need merging */
-        rfc1035_rr *result = (rfc1035_rr*) xmalloc( sizeof(rfc1035_rr)*(n + q->initial_AAAA.count) );
-        rfc1035_rr *tmp = result;
-
-        debugs(78, 6, HERE << "Merging DNS results " << q->name << " AAAA has " << q->initial_AAAA.count << " RR, A has " << n << " RR");
-
-        if (Config.dns.v4_first) {
-            memcpy( tmp, message->answer, (sizeof(rfc1035_rr)*n) );
-            tmp += n;
-            /* free the RR object without freeing its child strings (they are now taken by the copy above) */
-            safe_free(message->answer);
-        }
-
-        memcpy(tmp, q->initial_AAAA.answers, (sizeof(rfc1035_rr)*(q->initial_AAAA.count)) );
-        tmp += q->initial_AAAA.count;
-        /* free the RR object without freeing its child strings (they are now taken by the copy above) */
-        safe_free(q->initial_AAAA.answers);
-
-        if (!Config.dns.v4_first) {
-            memcpy( tmp, message->answer, (sizeof(rfc1035_rr)*n) );
-            /* free the RR object without freeing its child strings (they are now taken by the copy above) */
-            safe_free(message->answer);
-        }
-
-        n += q->initial_AAAA.count;
-        q->initial_AAAA.count = 0;
-        message->answer = result;
-        message->ancount = n;
-    } else if (q->initial_AAAA.count > 0 && n <= 0) {
-        /* initial of dual queries was the only result set. */
-        debugs(78, 6, HERE << "Merging DNS results " << q->name << " AAAA has " << q->initial_AAAA.count << " RR, A has " << n << " RR");
-        rfc1035RRDestroy(&(message->answer), n);
-        message->answer = q->initial_AAAA.answers;
-        n = q->initial_AAAA.count;
-        message->ancount = n;
+    /* Merge results */
+    message = q->message;
+    n = q->ancount;
+
+    while ( (q2 = q->slave) ) {
+        debugs(78, 6, HERE << "Merging DNS results " << q->name << " A has " << n << " RR, AAAA has " << q2->ancount << " RR");
+        q->slave = q2->slave;
+        if ( q2->ancount >= 0 ) {
+            if (n > 0 ) {
+                // two sets of RR need merging
+                rfc1035_rr *result = (rfc1035_rr*) xmalloc( sizeof(rfc1035_rr)*(n + q2->ancount) );
+                if (Config.dns.v4_first) {
+                    memcpy(result, message->answer, (sizeof(rfc1035_rr)*n) );
+                    memcpy(result+n, q2->message->answer, (sizeof(rfc1035_rr)*q2->ancount) );
+                } else {
+                    memcpy(result, q2->message->answer, (sizeof(rfc1035_rr)*q2->ancount) );
+                    memcpy(result+q2->ancount, message->answer, (sizeof(rfc1035_rr)*n) );
+                }
+                n += q2->ancount;
+                safe_free(message->answer);
+                message->answer = result;
+                message->ancount += q2->message->ancount;
+                safe_free(q2->message->answer);
+                q2->message->answer = NULL;
+            } else if (n < 0 || q2->ancount > 0) {
+                // first set empty / failed
+                rfc1035MessageDestroy(&message);
+                message = q->message = q2->message;
+                q2->message = NULL;
+                n = q2->ancount;
+            }
+        }
+        rfc1035MessageDestroy(&q2->message);
+        cbdataFree(q2);
     }
-    /* else initial results were empty. just use the final set as authoritative */
 
     debugs(78, 6, HERE << "Sending " << n << " DNS results to caller.");
     idnsCallback(q, message->answer, n, rfc1035ErrorMessage(n));
@@ -1375,7 +1338,7 @@
 
         debugs(78, 3, "idnsCheckQueue: ID " << q->xact_id <<
                " QID 0x"  << std::hex << std::setfill('0')  <<
-               std::setw(4) << q->msg_id << ": timeout" );
+               std::setw(4) << q->query_id << ": timeout" );
 
         dlinkDelete(&q->lru, &lru_list);
 
@@ -1383,7 +1346,7 @@
             idnsSendQuery(q);
         } else {
             debugs(78, 2, "idnsCheckQueue: ID " << q->xact_id <<
-                   " QID 0x" << std::hex << q->msg_id <<
+                   " QID 0x" << std::hex << q->query_id <<
                    " : giving up after " << std::dec << q->nsends << " tries and " <<
                    std::setw(5)<< std::setprecision(2) << tvSubDsec(q->start_t, current_time) << " seconds");
 
@@ -1492,7 +1455,7 @@
 }
 
 void
-idnsInit(void)
+dnsInit(void)
 {
     static int init = 0;
 
@@ -1500,30 +1463,30 @@
     CBDATA_INIT_TYPE(idns_query);
 
     if (DnsSocketA < 0 && DnsSocketB < 0) {
-        Ip::Address addrA; // since we don't want to alter Config.Addrs.udp_* and dont have one of our own.
+        Ip::Address addrV6; // since we don't want to alter Config.Addrs.udp_* and dont have one of our own.
 
         if (!Config.Addrs.udp_outgoing.IsNoAddr())
-            addrA = Config.Addrs.udp_outgoing;
+            addrV6 = Config.Addrs.udp_outgoing;
         else
-            addrA = Config.Addrs.udp_incoming;
+            addrV6 = Config.Addrs.udp_incoming;
 
-        Ip::Address addrB = addrA;
-        addrA.SetIPv4();
+        Ip::Address addrV4 = addrV6;
+        addrV4.SetIPv4();
 
-        if (Ip::EnableIpv6 && addrB.IsIPv6()) {
-            debugs(78, 2, "idnsInit: attempt open DNS socket to: " << addrB);
+        if (Ip::EnableIpv6 && addrV6.IsIPv6()) {
+            debugs(78, 2, "idnsInit: attempt open DNS socket to: " << addrV6);
             DnsSocketB = comm_open_listener(SOCK_DGRAM,
                                             IPPROTO_UDP,
-                                            addrB,
+                                            addrV6,
                                             COMM_NONBLOCKING,
                                             "DNS Socket IPv6");
         }
 
-        if (addrA.IsIPv4()) {
-            debugs(78, 2, "idnsInit: attempt open DNS socket to: " << addrA);
+        if (addrV4.IsIPv4()) {
+            debugs(78, 2, "idnsInit: attempt open DNS socket to: " << addrV4);
             DnsSocketA = comm_open_listener(SOCK_DGRAM,
                                             IPPROTO_UDP,
-                                            addrA,
+                                            addrV4,
                                             COMM_NONBLOCKING,
                                             "DNS Socket IPv4");
         }
@@ -1536,12 +1499,12 @@
          */
         if (DnsSocketB >= 0) {
             comm_local_port(DnsSocketB);
-            debugs(78, 1, "DNS Socket created at " << addrB << ", FD " << DnsSocketB);
+            debugs(78, 1, "DNS Socket created at " << addrV6 << ", FD " << DnsSocketB);
             Comm::SetSelect(DnsSocketB, COMM_SELECT_READ, idnsRead, NULL, 0);
         }
         if (DnsSocketA >= 0) {
             comm_local_port(DnsSocketA);
-            debugs(78, 1, "DNS Socket created at " << addrA << ", FD " << DnsSocketA);
+            debugs(78, 1, "DNS Socket created at " << addrV4 << ", FD " << DnsSocketA);
             Comm::SetSelect(DnsSocketA, COMM_SELECT_READ, idnsRead, NULL, 0);
         }
     }
@@ -1589,7 +1552,7 @@
 }
 
 void
-idnsShutdown(void)
+dnsShutdown(void)
 {
     if (DnsSocketA < 0 && DnsSocketB < 0)
         return;
@@ -1629,6 +1592,7 @@
     q = cbdataAlloc(idns_query);
     // idns_query is POD so no constructors are called after allocation
     q->xact_id.change();
+    // no query_id on this instance.
 
     q->callback = callback;
 
@@ -1644,10 +1608,31 @@
 static void
 idnsCacheQuery(idns_query *q)
 {
-    q->hash.key = q->query.name;
+    q->hash.key = q->orig;
     hash_join(idns_lookup_hash, &q->hash);
 }
 
+static void
+idnsSendSlaveAAAAQuery(idns_query *master)
+{
+    idns_query *q = cbdataAlloc(idns_query);
+    memcpy(q->name, master->name, sizeof(q->name));
+    memcpy(q->orig, master->orig, sizeof(q->orig));
+    q->master = master;
+    q->query_id = idnsQueryID();
+    q->sz = rfc3596BuildAAAAQuery(q->name, q->buf, sizeof(q->buf), q->query_id, &q->query, Config.dns.packet_max);
+    q->slave = master->slave;
+
+    debugs(78, 3, "idnsALookup: buf is " << q->sz << " bytes for " << q->name <<
+           ", id = 0x" << std::hex << q->query_id);
+    if (!q->sz) {
+        cbdataFree(q);
+        return;
+    }
+    master->slave = q;
+    idnsSendQuery(q);
+}
+
 void
 idnsALookup(const char *name, IDNSCB * callback, void *data)
 {
@@ -1661,6 +1646,7 @@
     q = cbdataAlloc(idns_query);
     // idns_query is POD so no constructors are called after allocation
     q->xact_id.change();
+    q->query_id = idnsQueryID();
 
     for (i = 0; i < strlen(name); i++)
         if (name[i] == '.')
@@ -1682,14 +1668,8 @@
         debugs(78, 3, "idnsALookup: searchpath used for " << q->name);
     }
 
-    if (Ip::EnableIpv6) {
-        q->sz = rfc3596BuildAAAAQuery(q->name, q->buf, sizeof(q->buf), 0, &q->query, Config.dns.packet_max);
-        q->need_A = true;
-    } else {
-        // see EDNS notes at top of file why this sends 0
-        q->sz = rfc3596BuildAQuery(q->name, q->buf, sizeof(q->buf), 0, &q->query, 0);
-        q->need_A = false;
-    }
+    // see EDNS notes at top of file why this sends 0
+    q->sz = rfc3596BuildAQuery(q->name, q->buf, sizeof(q->buf), q->query_id, &q->query, 0);
 
     if (q->sz < 0) {
         /* problem with query data -- query not sent */
@@ -1699,13 +1679,17 @@
     }
 
     debugs(78, 3, "idnsALookup: buf is " << q->sz << " bytes for " << q->name <<
-           ", id = 0x" << std::hex << q->msg_id);
+           ", id = 0x" << std::hex << q->query_id);
 
     q->callback = callback;
     q->callback_data = cbdataReference(data);
 
     idnsCacheQuery(q);
     idnsSendQuery(q);
+
+    if (Ip::EnableIpv6)
+        idnsSendSlaveAAAAQuery(q);
+
 }
 
 void
@@ -1721,6 +1705,7 @@
 
     // idns_query is POD so no constructors are called after allocation
     q->xact_id.change();
+    q->query_id = idnsQueryID();
 
     if (addr.IsIPv6()) {
         struct in6_addr addr6;
@@ -1733,9 +1718,6 @@
         q->sz = rfc3596BuildPTRQuery4(addr4, q->buf, sizeof(q->buf), 0, &q->query, 0);
     }
 
-    /* PTR does not do inbound A/AAAA */
-    q->need_A = false;
-
     if (q->sz < 0) {
         /* problem with query data -- query not sent */
         callback(data, NULL, 0, "Internal error");
@@ -1749,7 +1731,7 @@
     }
 
     debugs(78, 3, "idnsPTRLookup: buf is " << q->sz << " bytes for " << ip <<
-           ", id = 0x" << std::hex << q->msg_id);
+           ", id = 0x" << std::hex << q->query_id);
 
     q->callback = callback;
     q->callback_data = cbdataReference(data);
@@ -1763,7 +1745,7 @@
  * The function to return the DNS via SNMP
  */
 variable_list *
-snmp_netIdnsFn(variable_list * Var, snint * ErrP)
+snmp_netDnsFn(variable_list * Var, snint * ErrP)
 {
     int i, n = 0;
     variable_list *Answer = NULL;
@@ -1811,4 +1793,4 @@
 }
 
 #endif /*SQUID_SNMP */
-#endif /* USE_DNSSERVERS */
+#endif /* USE_DNSHELPER */
diff -u -r -N squid-3.2.0.14/src/DnsLookupDetails.cc squid-3.2.0.15/src/DnsLookupDetails.cc
--- squid-3.2.0.14/src/DnsLookupDetails.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/DnsLookupDetails.cc	2012-02-06 04:52:31.000000000 +1300
@@ -2,7 +2,7 @@
  * DEBUG: section 78    DNS lookups
  */
 
-#include "config.h"
+#include "squid.h"
 #include "DnsLookupDetails.h"
 
 DnsLookupDetails::DnsLookupDetails(): wait(-1)
diff -u -r -N squid-3.2.0.14/src/dnsserver.cc squid-3.2.0.15/src/dnsserver.cc
--- squid-3.2.0.14/src/dnsserver.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/dnsserver.cc	2012-02-06 04:52:31.000000000 +1300
@@ -30,7 +30,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 
 #if HAVE_UNISTD_H
 #include <unistd.h>
diff -u -r -N squid-3.2.0.14/src/enums.h squid-3.2.0.15/src/enums.h
--- squid-3.2.0.14/src/enums.h	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/enums.h	2012-02-06 04:52:31.000000000 +1300
@@ -228,7 +228,7 @@
     // following pools are initialized late by their component if needed (or never)
     MEM_FQDNCACHE_ENTRY,
     MEM_FWD_SERVER,
-#if !USE_DNSSERVERS
+#if !USE_DNSHELPER
     MEM_IDNS_QUERY,
 #endif
     MEM_IPCACHE_ENTRY,
diff -u -r -N squid-3.2.0.14/src/errorpage.cc squid-3.2.0.15/src/errorpage.cc
--- squid-3.2.0.14/src/errorpage.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/errorpage.cc	2012-02-06 04:52:31.000000000 +1300
@@ -31,7 +31,7 @@
  *  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111, USA.
  *
  */
-#include "config.h"
+#include "squid.h"
 #include "comm/Connection.h"
 #include "comm/Write.h"
 #include "errorpage.h"
@@ -142,7 +142,7 @@
 class ErrorPageFile: public TemplateFile
 {
 public:
-    ErrorPageFile(const char *name): TemplateFile(name) { textBuf.init();}
+    ErrorPageFile(const char *name, const err_type code): TemplateFile(name,code) { textBuf.init();}
 
     /// The template text data read from disk
     const char *text() { return textBuf.content(); }
@@ -195,7 +195,7 @@
              *  (a) default language translation directory (error_default_language)
              *  (b) admin specified custom directory (error_directory)
              */
-            ErrorPageFile  errTmpl(err_type_str[i]);
+            ErrorPageFile errTmpl(err_type_str[i], i);
             error_text[i] = errTmpl.loadDefault() ? xstrdup(errTmpl.text()) : NULL;
         } else {
             /** \par
@@ -210,7 +210,7 @@
 
             if (strchr(pg, ':') == NULL) {
                 /** But only if they are not redirection URL. */
-                ErrorPageFile  errTmpl(pg);
+                ErrorPageFile errTmpl(pg, ERR_MAX);
                 error_text[i] = errTmpl.loadDefault() ? xstrdup(errTmpl.text()) : NULL;
             }
         }
@@ -220,7 +220,7 @@
 
     // look for and load stylesheet into global MemBuf for it.
     if (Config.errorStylesheet) {
-        ErrorPageFile  tmpl("StylesSheet");
+        ErrorPageFile tmpl("StylesSheet", ERR_MAX);
         tmpl.loadFromFile(Config.errorStylesheet);
         error_stylesheet.Printf("%s",tmpl.text());
     }
@@ -265,7 +265,7 @@
     return NULL;
 }
 
-TemplateFile::TemplateFile(const char *name): silent(false), wasLoaded(false), templateName(name)
+TemplateFile::TemplateFile(const char *name, const err_type code): silent(false), wasLoaded(false), templateName(name), templateCode(code)
 {
     assert(name);
 }
@@ -287,7 +287,7 @@
     /** test error_default_language location */
     if (!loaded() && Config.errorDefaultLanguage) {
         if (!tryLoadTemplate(Config.errorDefaultLanguage)) {
-            debugs(1, DBG_CRITICAL, "Unable to load default error language files. Reset to backups.");
+            debugs(1, (templateCode < TCP_RESET ? DBG_CRITICAL : 3), "Unable to load default error language files. Reset to backups.");
         }
     }
 #endif
@@ -298,8 +298,11 @@
     }
 
     /* giving up if failed */
-    if (!loaded())
-        fatal("failed to find or read error text file.");
+    if (!loaded()) {
+        debugs(1, (templateCode < TCP_RESET ? DBG_CRITICAL : 3), "WARNING: failed to find or read error text file " << templateName);
+        parse("Internal Error: Missing Template ", 33, '\0');
+        parse(templateName.termedBuf(), templateName.size(), '\0');
+    }
 
     return true;
 }
@@ -343,7 +346,7 @@
 
     if (fd < 0) {
         /* with dynamic locale negotiation we may see some failures before a success. */
-        if (!silent)
+        if (!silent && templateCode < TCP_RESET)
             debugs(4, DBG_CRITICAL, HERE << "'" << path << "': " << xstrerror());
         wasLoaded = false;
         return wasLoaded;
@@ -1228,7 +1231,7 @@
     assert(page_id > ERR_NONE && page_id < error_page_count);
 
 #if USE_ERR_LOCALES
-    ErrorPageFile  *localeTmpl = NULL;
+    ErrorPageFile *localeTmpl = NULL;
 
     /** error_directory option in squid.conf overrides translations.
      * Custom errors are always found either in error_directory or the templates directory.
@@ -1238,7 +1241,7 @@
         if (err_language && err_language != Config.errorDefaultLanguage)
             safe_free(err_language);
 
-        localeTmpl = new ErrorPageFile(err_type_str[page_id]);
+        localeTmpl = new ErrorPageFile(err_type_str[page_id], static_cast<err_type>(page_id));
         if (localeTmpl->loadFor(request)) {
             m = localeTmpl->text();
             assert(localeTmpl->language());
diff -u -r -N squid-3.2.0.14/src/errorpage.h squid-3.2.0.15/src/errorpage.h
--- squid-3.2.0.14/src/errorpage.h	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/errorpage.h	2012-02-06 04:52:31.000000000 +1300
@@ -34,7 +34,7 @@
 #ifndef   SQUID_ERRORPAGE_H
 #define   SQUID_ERRORPAGE_H
 
-#include "squid.h"
+#include "squid-old.h"
 #if USE_AUTH
 #include "auth/UserRequest.h"
 #endif
@@ -150,7 +150,7 @@
     char *err_language;
     http_status httpStatus;
 #if USE_AUTH
-    AuthUserRequest::Pointer auth_user_request;
+    Auth::UserRequest::Pointer auth_user_request;
 #endif
     HttpRequest *request;
     char *url;
@@ -254,7 +254,7 @@
 class TemplateFile
 {
 public:
-    TemplateFile(const char *name);
+    TemplateFile(const char *name, const err_type code);
     virtual ~TemplateFile() {}
 
     /// return true if the data loaded from disk without any problem
@@ -301,6 +301,7 @@
     bool wasLoaded; ///< True if the template data read from disk without any problem
     String errLanguage; ///< The error language of the template.
     String templateName; ///< The name of the template
+    err_type templateCode; ///< The internal code for this template.
 };
 
 /**
diff -u -r -N squid-3.2.0.14/src/err_type.h squid-3.2.0.15/src/err_type.h
--- squid-3.2.0.14/src/err_type.h	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/err_type.h	2012-02-06 04:52:31.000000000 +1300
@@ -35,6 +35,7 @@
     ERR_INVALID_URL,
     ERR_ZERO_SIZE_OBJECT,
     ERR_PRECONDITION_FAILED,
+    ERR_CONFLICT_HOST,
 
     /* FTP Errors */
     ERR_FTP_DISABLED,
@@ -59,7 +60,13 @@
     ERR_DIR_LISTING,            /* Display of remote directory (FTP, Gopher) */
     ERR_SQUID_SIGNATURE,        /* not really an error */
     ERR_SHUTTING_DOWN,
-    TCP_RESET,
+
+    // NOTE: error types defined below TCP_RESET are optional and do not generate
+    //       a log warning if the files are missing
+    TCP_RESET,                  // Send TCP RST packet instead of error page
+
+    /* Cache Manager GUI can install a manager index/home page */
+    MGR_INDEX,
 
     ERR_MAX
 } err_type;
diff -u -r -N squid-3.2.0.14/src/esi/Assign.cc squid-3.2.0.15/src/esi/Assign.cc
--- squid-3.2.0.14/src/esi/Assign.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/esi/Assign.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 
 /* MS Visual Studio Projects are monolithic, so we need the following
  * #if to exclude the ESI code from compile process when not needed.
diff -u -r -N squid-3.2.0.14/src/esi/Assign.h squid-3.2.0.15/src/esi/Assign.h
--- squid-3.2.0.14/src/esi/Assign.h	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/esi/Assign.h	2012-02-06 04:52:31.000000000 +1300
@@ -36,7 +36,7 @@
 #ifndef SQUID_ESIASSIGN_H
 #define SQUID_ESIASSIGN_H
 
-#include "squid.h"
+#include "squid-old.h"
 #include "esi/Element.h"
 #include "SquidString.h"
 #include "esi/VarState.h"
diff -u -r -N squid-3.2.0.14/src/esi/Attempt.h squid-3.2.0.15/src/esi/Attempt.h
--- squid-3.2.0.14/src/esi/Attempt.h	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/esi/Attempt.h	2012-02-06 04:52:31.000000000 +1300
@@ -36,7 +36,7 @@
 #ifndef SQUID_ESIATTEMPT_H
 #define SQUID_ESIATTEMPT_H
 
-#include "squid.h"
+#include "squid-old.h"
 #include "esi/Element.h"
 #include "esi/Sequence.h"
 
diff -u -r -N squid-3.2.0.14/src/esi/Context.cc squid-3.2.0.15/src/esi/Context.cc
--- squid-3.2.0.14/src/esi/Context.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/esi/Context.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 
 /* MS Visual Studio Projects are monolithic, so we need the following
  * #if to exclude the ESI code from compile process when not needed.
diff -u -r -N squid-3.2.0.14/src/esi/CustomParser.cc squid-3.2.0.15/src/esi/CustomParser.cc
--- squid-3.2.0.14/src/esi/CustomParser.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/esi/CustomParser.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "esi/CustomParser.h"
 #include "Trie.h"
 #include "TrieCharTransform.h"
diff -u -r -N squid-3.2.0.14/src/esi/ElementList.h squid-3.2.0.15/src/esi/ElementList.h
--- squid-3.2.0.14/src/esi/ElementList.h	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/esi/ElementList.h	2012-02-06 04:52:31.000000000 +1300
@@ -36,7 +36,7 @@
 #ifndef SQUID_ELEMENTLIST_H
 #define SQUID_ELEMENTLIST_H
 
-#include "squid.h"
+#include "squid-old.h"
 #include "esi/Element.h"
 
 class ElementList
diff -u -r -N squid-3.2.0.14/src/esi/Esi.cc squid-3.2.0.15/src/esi/Esi.cc
--- squid-3.2.0.14/src/esi/Esi.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/esi/Esi.cc	2012-02-06 04:52:31.000000000 +1300
@@ -31,7 +31,7 @@
  * Copyright (c) 2003, Robert Collins <robertc@squid-cache.org>
  */
 
-#include "squid.h"
+#include "squid-old.h"
 
 /* MS Visual Studio Projects are monolithic, so we need the following
  * #if to exclude the ESI code from compile process when not needed.
diff -u -r -N squid-3.2.0.14/src/esi/Except.h squid-3.2.0.15/src/esi/Except.h
--- squid-3.2.0.14/src/esi/Except.h	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/esi/Except.h	2012-02-06 04:52:31.000000000 +1300
@@ -36,7 +36,7 @@
 #ifndef SQUID_ESIEXCEPT_H
 #define SQUID_ESIEXCEPT_H
 
-#include "squid.h"
+#include "squid-old.h"
 #include "esi/Element.h"
 #include "esi/Sequence.h"
 
diff -u -r -N squid-3.2.0.14/src/esi/ExpatParser.cc squid-3.2.0.15/src/esi/ExpatParser.cc
--- squid-3.2.0.14/src/esi/ExpatParser.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/esi/ExpatParser.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 
 #if USE_SQUID_ESI && HAVE_LIBEXPAT
 
diff -u -r -N squid-3.2.0.14/src/esi/Expression.cc squid-3.2.0.15/src/esi/Expression.cc
--- squid-3.2.0.14/src/esi/Expression.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/esi/Expression.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "esi/Expression.h"
 
 /* stack precedence rules:
diff -u -r -N squid-3.2.0.14/src/esi/Expression.h squid-3.2.0.15/src/esi/Expression.h
--- squid-3.2.0.14/src/esi/Expression.h	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/esi/Expression.h	2012-02-06 04:52:31.000000000 +1300
@@ -36,7 +36,7 @@
 #ifndef SQUID_ESIEXPRESSION_H
 #define SQUID_ESIEXPRESSION_H
 
-#include "squid.h"
+#include "squid-old.h"
 
 class ESIExpression
 {
diff -u -r -N squid-3.2.0.14/src/esi/Include.cc squid-3.2.0.15/src/esi/Include.cc
--- squid-3.2.0.14/src/esi/Include.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/esi/Include.cc	2012-02-06 04:52:31.000000000 +1300
@@ -34,7 +34,7 @@
  * Copyright (c) 2003, Robert Collins <robertc@squid-cache.org>
  */
 
-#include "squid.h"
+#include "squid-old.h"
 
 /* MS Visual Studio Projects are monolithic, so we need the following
  * #if to exclude the ESI code from compile process when not needed.
diff -u -r -N squid-3.2.0.14/src/esi/Include.h squid-3.2.0.15/src/esi/Include.h
--- squid-3.2.0.14/src/esi/Include.h	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/esi/Include.h	2012-02-06 04:52:31.000000000 +1300
@@ -36,7 +36,7 @@
 #ifndef SQUID_ESIINCLUDE_H
 #define SQUID_ESIINCLUDE_H
 
-#include "squid.h"
+#include "squid-old.h"
 #include "esi/Segment.h"
 #include "esi/Element.h"
 #include "esi/Context.h"
diff -u -r -N squid-3.2.0.14/src/esi/Libxml2Parser.cc squid-3.2.0.15/src/esi/Libxml2Parser.cc
--- squid-3.2.0.14/src/esi/Libxml2Parser.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/esi/Libxml2Parser.cc	2012-02-06 04:52:31.000000000 +1300
@@ -37,7 +37,7 @@
  * mail@joachim-bauch.de
  */
 
-#include "squid.h"
+#include "squid-old.h"
 
 #if USE_SQUID_ESI && HAVE_LIBXML2
 
diff -u -r -N squid-3.2.0.14/src/esi/Literal.h squid-3.2.0.15/src/esi/Literal.h
--- squid-3.2.0.14/src/esi/Literal.h	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/esi/Literal.h	2012-02-06 04:52:31.000000000 +1300
@@ -36,7 +36,7 @@
 #ifndef SQUID_ESILITERAL_H
 #define SQUID_ESILITERAL_H
 
-#include "squid.h"
+#include "squid-old.h"
 #include "esi/Element.h"
 
 class ESIContext;
diff -u -r -N squid-3.2.0.14/src/esi/Module.cc squid-3.2.0.15/src/esi/Module.cc
--- squid-3.2.0.14/src/esi/Module.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/esi/Module.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "squid.h"
+#include "squid-old.h"
 #include "esi/Module.h"
 #include "esi/CustomParser.h"
 #include "esi/Libxml2Parser.h"
diff -u -r -N squid-3.2.0.14/src/esi/Parser.cc squid-3.2.0.15/src/esi/Parser.cc
--- squid-3.2.0.14/src/esi/Parser.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/esi/Parser.cc	2012-02-06 04:52:31.000000000 +1300
@@ -32,7 +32,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "esi/Parser.h"
 
 char *ESIParser::Type = NULL;
diff -u -r -N squid-3.2.0.14/src/esi/Segment.cc squid-3.2.0.15/src/esi/Segment.cc
--- squid-3.2.0.14/src/esi/Segment.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/esi/Segment.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "esi/Segment.h"
 #include "SquidString.h"
 
diff -u -r -N squid-3.2.0.14/src/esi/Sequence.cc squid-3.2.0.15/src/esi/Sequence.cc
--- squid-3.2.0.14/src/esi/Sequence.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/esi/Sequence.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
  * Copyright (c) 2003, Robert Collins <robertc@squid-cache.org>
  */
 
-#include "squid.h"
+#include "squid-old.h"
 
 /* MS Visual Studio Projects are monolithic, so we need the following
  * #if to exclude the ESI code from compile process when not needed.
diff -u -r -N squid-3.2.0.14/src/esi/Sequence.h squid-3.2.0.15/src/esi/Sequence.h
--- squid-3.2.0.14/src/esi/Sequence.h	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/esi/Sequence.h	2012-02-06 04:52:31.000000000 +1300
@@ -36,7 +36,7 @@
 #ifndef SQUID_ESISEQUENCE_H
 #define SQUID_ESISEQUENCE_H
 
-#include "squid.h"
+#include "squid-old.h"
 #include "esi/Element.h"
 #include "esi/ElementList.h"
 
diff -u -r -N squid-3.2.0.14/src/esi/Var.h squid-3.2.0.15/src/esi/Var.h
--- squid-3.2.0.14/src/esi/Var.h	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/esi/Var.h	2012-02-06 04:52:31.000000000 +1300
@@ -36,7 +36,7 @@
 #ifndef SQUID_ESIVAR_H
 #define SQUID_ESIVAR_H
 
-#include "squid.h"
+#include "squid-old.h"
 #include "esi/Element.h"
 #include "esi/Sequence.h"
 
diff -u -r -N squid-3.2.0.14/src/esi/VarState.cc squid-3.2.0.15/src/esi/VarState.cc
--- squid-3.2.0.14/src/esi/VarState.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/esi/VarState.cc	2012-02-06 04:52:31.000000000 +1300
@@ -34,7 +34,7 @@
  * Copyright (c) 2003, Robert Collins <robertc@squid-cache.org>
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "esi/VarState.h"
 #include "HttpReply.h"
 
diff -u -r -N squid-3.2.0.14/src/ETag.cc squid-3.2.0.15/src/ETag.cc
--- squid-3.2.0.14/src/ETag.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/ETag.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 #include "ETag.h"
 
 #if HAVE_CSTRING
diff -u -r -N squid-3.2.0.14/src/eui/Config.cc squid-3.2.0.15/src/eui/Config.cc
--- squid-3.2.0.14/src/eui/Config.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/eui/Config.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "config.h"
+#include "squid.h"
 #include "eui/Config.h"
 
 Eui::EuiConfig Eui::TheConfig;
diff -u -r -N squid-3.2.0.14/src/eui/Eui48.cc squid-3.2.0.15/src/eui/Eui48.cc
--- squid-3.2.0.14/src/eui/Eui48.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/eui/Eui48.cc	2012-02-06 04:52:31.000000000 +1300
@@ -32,7 +32,7 @@
  * Copyright (c) 2003, Robert Collins <robertc@squid-cache.org>
  */
 
-#include "config.h"
+#include "squid.h"
 
 #if USE_SQUID_EUI
 
diff -u -r -N squid-3.2.0.14/src/eui/Eui64.cc squid-3.2.0.15/src/eui/Eui64.cc
--- squid-3.2.0.14/src/eui/Eui64.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/eui/Eui64.cc	2012-02-06 04:52:31.000000000 +1300
@@ -5,7 +5,7 @@
  * Copyright (c) 2009, Amos Jeffries <squid3@treenet.co.nz>
  */
 
-#include "config.h"
+#include "squid.h"
 
 #if USE_SQUID_EUI
 
diff -u -r -N squid-3.2.0.14/src/event.cc squid-3.2.0.15/src/event.cc
--- squid-3.2.0.14/src/event.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/event.cc	2012-02-06 04:52:31.000000000 +1300
@@ -32,7 +32,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 #include "compat/drand48.h"
 #include "event.h"
 #include "mgr/Registration.h"
diff -u -r -N squid-3.2.0.14/src/event.h squid-3.2.0.15/src/event.h
--- squid-3.2.0.14/src/event.h	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/event.h	2012-02-06 04:52:31.000000000 +1300
@@ -34,7 +34,7 @@
 #ifndef SQUID_EVENT_H
 #define SQUID_EVENT_H
 
-#include "squid.h"
+#include "squid-old.h"
 #include "Array.h"
 #include "AsyncEngine.h"
 
diff -u -r -N squid-3.2.0.14/src/EventLoop.cc squid-3.2.0.15/src/EventLoop.cc
--- squid-3.2.0.14/src/EventLoop.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/EventLoop.cc	2012-02-06 04:52:31.000000000 +1300
@@ -32,7 +32,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 #include "EventLoop.h"
 #include "base/AsyncCallQueue.h"
 
diff -u -r -N squid-3.2.0.14/src/EventLoop.h squid-3.2.0.15/src/EventLoop.h
--- squid-3.2.0.14/src/EventLoop.h	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/EventLoop.h	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
 #ifndef SQUID_EVENTLOOP_H
 #define SQUID_EVENTLOOP_H
 
-#include "squid.h"
+#include "squid-old.h"
 #include "Array.h"
 #include "AsyncEngine.h"
 #include "SquidTime.h"
diff -u -r -N squid-3.2.0.14/src/external_acl.cc squid-3.2.0.15/src/external_acl.cc
--- squid-3.2.0.14/src/external_acl.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/external_acl.cc	2012-02-06 04:52:31.000000000 +1300
@@ -40,7 +40,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "mgr/Registration.h"
 #include "ExternalACL.h"
 #include "ExternalACLEntry.h"
@@ -747,6 +747,28 @@
     safe_free (class_);
 }
 
+static void
+copyResultsFromEntry(HttpRequest *req, external_acl_entry *entry)
+{
+    if (req) {
+#if USE_AUTH
+        if (entry->user.size())
+            req->extacl_user = entry->user;
+
+        if (entry->password.size())
+            req->extacl_passwd = entry->password;
+#endif
+        if (!req->tag.size())
+            req->tag = entry->tag;
+
+        if (entry->log.size())
+            req->extacl_log = entry->log;
+
+        if (entry->message.size())
+            req->extacl_message = entry->message;
+    }
+}
+
 static int
 aclMatchExternal(external_acl_data *acl, ACLFilledChecklist *ch)
 {
@@ -834,25 +856,7 @@
     external_acl_message = entry->message.termedBuf();
 
     debugs(82, 2, "aclMatchExternal: " << acl->def->name << " = " << result);
-
-    if (ch->request) {
-#if USE_AUTH
-        if (entry->user.size())
-            ch->request->extacl_user = entry->user;
-
-        if (entry->password.size())
-            ch->request->extacl_passwd = entry->password;
-#endif
-        if (!ch->request->tag.size())
-            ch->request->tag = entry->tag;
-
-        if (entry->log.size())
-            ch->request->extacl_log = entry->log;
-
-        if (entry->message.size())
-            ch->request->extacl_message = entry->message;
-    }
-
+    copyResultsFromEntry(ch->request, entry);
     return result;
 }
 
@@ -1479,7 +1483,7 @@
 #if USE_AUTH
             debugs(82, 4, "externalAclLookup: user=" << entry->user);
 #endif
-
+            copyResultsFromEntry(ch->request, entry);
         }
 
         callback(callback_data, entry);
diff -u -r -N squid-3.2.0.14/src/ExternalACLEntry.cc squid-3.2.0.15/src/ExternalACLEntry.cc
--- squid-3.2.0.14/src/ExternalACLEntry.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/ExternalACLEntry.cc	2012-02-06 04:52:31.000000000 +1300
@@ -41,7 +41,7 @@
  * Copyright (c) 2003, Robert Collins <robertc@squid-cache.org>
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "ExternalACLEntry.h"
 #include "SquidTime.h"
 
diff -u -r -N squid-3.2.0.14/src/FadingCounter.cc squid-3.2.0.15/src/FadingCounter.cc
--- squid-3.2.0.14/src/FadingCounter.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/FadingCounter.cc	2012-02-06 04:52:31.000000000 +1300
@@ -2,7 +2,7 @@
  * $Id$
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "base/TextException.h"
 #include "SquidTime.h"
 #include "FadingCounter.h"
diff -u -r -N squid-3.2.0.14/src/fd.cc squid-3.2.0.15/src/fd.cc
--- squid-3.2.0.14/src/fd.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/fd.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "comm/Loops.h"
 #include "fde.h"
 #include "SquidTime.h"
diff -u -r -N squid-3.2.0.14/src/fde.cc squid-3.2.0.15/src/fde.cc
--- squid-3.2.0.14/src/fde.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/fde.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "fde.h"
 #include "SquidTime.h"
 #include "Store.h"
diff -u -r -N squid-3.2.0.14/src/filemap.cc squid-3.2.0.15/src/filemap.cc
--- squid-3.2.0.14/src/filemap.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/filemap.cc	2012-02-06 04:52:31.000000000 +1300
@@ -30,7 +30,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 #include "Debug.h"
 #include "FileMap.h"
 
diff -u -r -N squid-3.2.0.14/src/format/Config.cc squid-3.2.0.15/src/format/Config.cc
--- squid-3.2.0.14/src/format/Config.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/format/Config.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "config.h"
+#include "squid.h"
 #include "format/Config.h"
 #include "protos.h"
 #include <list>
diff -u -r -N squid-3.2.0.14/src/format/Format.cc squid-3.2.0.15/src/format/Format.cc
--- squid-3.2.0.14/src/format/Format.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/format/Format.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "config.h"
+#include "squid.h"
 #include "AccessLogEntry.h"
 #include "comm/Connection.h"
 #include "err_detail_type.h"
@@ -315,10 +315,8 @@
             break;
 
         case LFT_CLIENT_IP_ADDRESS:
-            if (al->cache.caddr.IsNoAddr()) // e.g., ICAP OPTIONS lack client
-                out = "-";
-            else
-                out = al->cache.caddr.NtoA(tmp,1024);
+            al->getLogClientIp(tmp, sizeof(tmp));
+            out = tmp;
             break;
 
         case LFT_CLIENT_FQDN:
@@ -373,8 +371,10 @@
 
         case LFT_LOCAL_LISTENING_IP: {
             // avoid logging a dash if we have reliable info
-            const bool interceptedAtKnownPort = (al->request->flags.spoof_client_ip ||
-                                                 al->request->flags.intercepted) && al->cache.port;
+            const bool interceptedAtKnownPort = al->request ?
+                                                (al->request->flags.spoof_client_ip ||
+                                                 al->request->flags.intercepted) && al->cache.port :
+                                                false;
             if (interceptedAtKnownPort) {
                 const bool portAddressConfigured = !al->cache.port->s.IsAnyAddr();
                 if (portAddressConfigured)
diff -u -r -N squid-3.2.0.14/src/format/Quoting.cc squid-3.2.0.15/src/format/Quoting.cc
--- squid-3.2.0.14/src/format/Quoting.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/format/Quoting.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "config.h"
+#include "squid.h"
 #include "format/Quoting.h"
 
 static const char c2x[] =
diff -u -r -N squid-3.2.0.14/src/format/Token.cc squid-3.2.0.15/src/format/Token.cc
--- squid-3.2.0.14/src/format/Token.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/format/Token.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "config.h"
+#include "squid.h"
 #include "format/Config.h"
 #include "format/Token.h"
 #include "format/TokenTableEntry.h"
diff -u -r -N squid-3.2.0.14/src/forward.cc squid-3.2.0.15/src/forward.cc
--- squid-3.2.0.14/src/forward.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/forward.cc	2012-02-06 04:52:31.000000000 +1300
@@ -31,7 +31,7 @@
  */
 
 
-#include "squid.h"
+#include "squid-old.h"
 #include "forward.h"
 #include "acl/FilledChecklist.h"
 #include "acl/Gadgets.h"
@@ -120,8 +120,9 @@
     // Bug 3243: CVE 2009-0801
     // Bypass of browser same-origin access control in intercepted communication
     // To resolve this we must force DIRECT and only to the original client destination.
-    if (Config.onoff.client_dst_passthru && request && !request->flags.redirected &&
-            (request->flags.intercepted || request->flags.spoof_client_ip)) {
+    const bool isIntercepted = request && !request->flags.redirected && (request->flags.intercepted || request->flags.spoof_client_ip);
+    const bool useOriginalDst = Config.onoff.client_dst_passthru || (request && !request->flags.hostVerified);
+    if (isIntercepted && useOriginalDst) {
         Comm::ConnectionPointer p = new Comm::Connection();
         p->remote = clientConn->local;
         p->peerType = ORIGINAL_DST;
diff -u -r -N squid-3.2.0.14/src/fqdncache.cc squid-3.2.0.15/src/fqdncache.cc
--- squid-3.2.0.14/src/fqdncache.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/fqdncache.cc	2012-02-06 04:52:31.000000000 +1300
@@ -32,11 +32,12 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "cbdata.h"
 #include "DnsLookupDetails.h"
 #include "event.h"
 #include "mgr/Registration.h"
+#include "SquidDns.h"
 #include "SquidTime.h"
 #include "Store.h"
 #include "wordlist.h"
@@ -127,7 +128,7 @@
 /// \ingroup FQDNCacheInternal
 static dlink_list lru_list;
 
-#if USE_DNSSERVERS
+#if USE_DNSHELPER
 static HLPCB fqdncacheHandleReply;
 static int fqdncacheParse(fqdncache_entry *, const char *buf);
 #else
@@ -339,7 +340,7 @@
 }
 
 /// \ingroup FQDNCacheInternal
-#if USE_DNSSERVERS
+#if USE_DNSHELPER
 static int
 fqdncacheParse(fqdncache_entry *f, const char *inbuf)
 {
@@ -491,7 +492,7 @@
  * Callback for handling DNS results.
  */
 static void
-#if USE_DNSSERVERS
+#if USE_DNSHELPER
 fqdncacheHandleReply(void *data, char *reply)
 #else
 fqdncacheHandleReply(void *data, rfc1035_rr * answers, int na, const char *error_message)
@@ -502,7 +503,7 @@
     ++FqdncacheStats.replies;
     const int age = f->age();
     statHistCount(&statCounter.dns.svc_time, age);
-#if USE_DNSSERVERS
+#if USE_DNSHELPER
 
     fqdncacheParse(f, reply);
 #else
@@ -577,8 +578,7 @@
     f->handlerData = cbdataReference(handlerData);
     f->request_time = current_time;
     c = new generic_cbdata(f);
-#if USE_DNSSERVERS
-
+#if USE_DNSHELPER
     dnsSubmit(hashKeyStr(&f->hash), fqdncacheHandleReply, c);
 #else
     idnsPTRLookup(addr, fqdncacheHandleReply, c);
diff -u -r -N squid-3.2.0.14/src/fs/aufs/StoreFSaufs.cc squid-3.2.0.15/src/fs/aufs/StoreFSaufs.cc
--- squid-3.2.0.14/src/fs/aufs/StoreFSaufs.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/fs/aufs/StoreFSaufs.cc	2012-02-06 04:52:31.000000000 +1300
@@ -35,10 +35,10 @@
 
 /* TODO: remove this file as unused */
 
-#include "config.h"
+#include "squid.h"
 
 #if 0
-#include "squid.h"
+#include "squid-old.h"
 #include "StoreFileSystem.h"
 #include "DiskIO/DiskIOModule.h"
 #endif
diff -u -r -N squid-3.2.0.14/src/fs/coss/store_dir_coss.cc squid-3.2.0.15/src/fs/coss/store_dir_coss.cc
--- squid-3.2.0.14/src/fs/coss/store_dir_coss.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/fs/coss/store_dir_coss.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "CossSwapDir.h"
 #include "Store.h"
 
diff -u -r -N squid-3.2.0.14/src/fs/coss/StoreFScoss.cc squid-3.2.0.15/src/fs/coss/StoreFScoss.cc
--- squid-3.2.0.14/src/fs/coss/StoreFScoss.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/fs/coss/StoreFScoss.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
  * Copyright (c) 2003, Robert Collins <robertc@squid-cache.org>
  */
 
-#include "config.h"
+#include "squid.h"
 #include "StoreFileSystem.h"
 #include "StoreFScoss.h"
 #include "mgr/Registration.h"
diff -u -r -N squid-3.2.0.14/src/fs/coss/store_io_coss.cc squid-3.2.0.15/src/fs/coss/store_io_coss.cc
--- squid-3.2.0.14/src/fs/coss/store_io_coss.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/fs/coss/store_io_coss.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "CossSwapDir.h"
 #include "Store.h"
 #include "store_coss.h"
diff -u -r -N squid-3.2.0.14/src/fs/diskd/StoreFSdiskd.cc squid-3.2.0.15/src/fs/diskd/StoreFSdiskd.cc
--- squid-3.2.0.14/src/fs/diskd/StoreFSdiskd.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/fs/diskd/StoreFSdiskd.cc	2012-02-06 04:52:31.000000000 +1300
@@ -35,7 +35,7 @@
 
 /* TODO: remove this file as unused */
 
-#include "config.h"
+#include "squid.h"
 #if 0
 #include "StoreFileSystem.h"
 #include "DiskIO/DiskIOModule.h"
diff -u -r -N squid-3.2.0.14/src/fs/Module.cc squid-3.2.0.15/src/fs/Module.cc
--- squid-3.2.0.14/src/fs/Module.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/fs/Module.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "squid.h"
+#include "squid-old.h"
 #include "Module.h"
 #if defined(HAVE_FS_UFS) || defined(HAVE_FS_AUFS) || defined(HAVE_FS_DISKD)
 #include "fs/ufs/StoreFSufs.h"
diff -u -r -N squid-3.2.0.14/src/fs/rock/RockIoRequests.cc squid-3.2.0.15/src/fs/rock/RockIoRequests.cc
--- squid-3.2.0.14/src/fs/rock/RockIoRequests.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/fs/rock/RockIoRequests.cc	2012-02-06 04:52:31.000000000 +1300
@@ -4,7 +4,7 @@
  * DEBUG: section 79    Disk IO Routines
  */
 
-#include "config.h"
+#include "squid.h"
 #include "fs/rock/RockIoRequests.h"
 
 CBDATA_NAMESPACED_CLASS_INIT(Rock, ReadRequest);
diff -u -r -N squid-3.2.0.14/src/fs/rock/RockIoState.cc squid-3.2.0.15/src/fs/rock/RockIoState.cc
--- squid-3.2.0.14/src/fs/rock/RockIoState.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/fs/rock/RockIoState.cc	2012-02-06 04:52:31.000000000 +1300
@@ -4,7 +4,7 @@
  * DEBUG: section 79    Disk IO Routines
  */
 
-#include "config.h"
+#include "squid.h"
 #include "MemObject.h"
 #include "Parsing.h"
 #include "DiskIO/DiskIOModule.h"
diff -u -r -N squid-3.2.0.14/src/fs/rock/RockRebuild.cc squid-3.2.0.15/src/fs/rock/RockRebuild.cc
--- squid-3.2.0.14/src/fs/rock/RockRebuild.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/fs/rock/RockRebuild.cc	2012-02-06 04:52:31.000000000 +1300
@@ -4,7 +4,7 @@
  * DEBUG: section 79    Disk IO Routines
  */
 
-#include "config.h"
+#include "squid.h"
 #include "fs/rock/RockRebuild.h"
 #include "fs/rock/RockSwapDir.h"
 #include "fs/rock/RockDbCell.h"
diff -u -r -N squid-3.2.0.14/src/fs/rock/RockStoreFileSystem.cc squid-3.2.0.15/src/fs/rock/RockStoreFileSystem.cc
--- squid-3.2.0.14/src/fs/rock/RockStoreFileSystem.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/fs/rock/RockStoreFileSystem.cc	2012-02-06 04:52:31.000000000 +1300
@@ -4,7 +4,7 @@
  * DEBUG: section 92    Storage File System
  */
 
-#include "config.h"
+#include "squid.h"
 #include "fs/rock/RockStoreFileSystem.h"
 #include "fs/rock/RockSwapDir.h"
 
diff -u -r -N squid-3.2.0.14/src/fs/rock/RockSwapDir.cc squid-3.2.0.15/src/fs/rock/RockSwapDir.cc
--- squid-3.2.0.14/src/fs/rock/RockSwapDir.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/fs/rock/RockSwapDir.cc	2012-02-06 04:52:31.000000000 +1300
@@ -4,7 +4,7 @@
  * DEBUG: section 47    Store Directory Routines
  */
 
-#include "config.h"
+#include "squid.h"
 #include "ConfigOption.h"
 #include "DiskIO/DiskIOModule.h"
 #include "DiskIO/DiskIOStrategy.h"
diff -u -r -N squid-3.2.0.14/src/fs/ufs/store_dir_ufs.cc squid-3.2.0.15/src/fs/ufs/store_dir_ufs.cc
--- squid-3.2.0.14/src/fs/ufs/store_dir_ufs.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/fs/ufs/store_dir_ufs.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "Store.h"
 #include "fde.h"
 #include "ufscommon.h"
@@ -760,13 +760,6 @@
     debugs(47, 3, "Cache Dir #" << index << " log opened on FD " << fd);
 }
 
-static void
-FreeHeader(void *address)
-{
-    StoreSwapLogHeader *anObject = static_cast <StoreSwapLogHeader *>(address);
-    delete anObject;
-}
-
 FILE *
 UFSSwapDir::openTmpSwapLog(int *clean_flag, int *zero_flag)
 {
@@ -805,9 +798,16 @@
     swaplog_fd = fd;
 
     {
-        StoreSwapLogHeader *header = new StoreSwapLogHeader;
-        file_write(swaplog_fd, -1, header, sizeof(*header),
-                   NULL, NULL, FreeHeader);
+        const StoreSwapLogHeader header;
+        MemBuf buf;
+        buf.init(header.record_size, header.record_size);
+        buf.append(reinterpret_cast<const char*>(&header), sizeof(header));
+        // Pad to keep in sync with UFSSwapDir::writeCleanStart().
+        // TODO: When MemBuf::spaceSize() is fixed not to subtract one,
+        // memset() space() with zeroes and use spaceSize() below.
+        buf.appended(static_cast<size_t>(header.record_size) - sizeof(header));
+        file_write(swaplog_fd, -1, buf.content(), buf.contentSize(),
+                   NULL, NULL, buf.freeFunc());
     }
 
     /* open a read-only stream of the old log */
@@ -893,6 +893,7 @@
     state->outbuf_offset = 0;
     /*copy the header */
     memcpy(state->outbuf, &header, sizeof(StoreSwapLogHeader));
+    // Leave a gap to keep in sync with UFSSwapDir::openTmpSwapLog().
     state->outbuf_offset += header.record_size;
 
     state->walker = repl->WalkInit(repl);
diff -u -r -N squid-3.2.0.14/src/fs/ufs/StoreFSufs.cc squid-3.2.0.15/src/fs/ufs/StoreFSufs.cc
--- squid-3.2.0.14/src/fs/ufs/StoreFSufs.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/fs/ufs/StoreFSufs.cc	2012-02-06 04:52:31.000000000 +1300
@@ -35,7 +35,7 @@
 
 /*TODO: remove this file as unused*/
 
-#include "config.h"
+#include "squid.h"
 #if 0
 #include "StoreFileSystem.h"
 #endif
diff -u -r -N squid-3.2.0.14/src/fs/ufs/store_io_ufs.cc squid-3.2.0.15/src/fs/ufs/store_io_ufs.cc
--- squid-3.2.0.14/src/fs/ufs/store_io_ufs.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/fs/ufs/store_io_ufs.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "Store.h"
 #include "ufscommon.h"
 #include "Generic.h"
diff -u -r -N squid-3.2.0.14/src/fs/ufs/ufscommon.cc squid-3.2.0.15/src/fs/ufs/ufscommon.cc
--- squid-3.2.0.14/src/fs/ufs/ufscommon.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/fs/ufs/ufscommon.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,10 +33,11 @@
  * Copyright (c) 2003, Robert Collins <robertc@squid-cache.org>
  */
 
-#include "config.h"
+#include "squid.h"
 #include "ufscommon.h"
 #include "Store.h"
 #include "fde.h"
+#include "SquidTime.h"
 #include "StoreMeta.h"
 #include "Generic.h"
 #include "StoreMetaUnpacker.h"
@@ -299,7 +300,6 @@
 
 RebuildState::RebuildState (RefCount<UFSSwapDir> aSwapDir) : sd (aSwapDir),LogParser(NULL), e(NULL), fromLog(true), _done (false)
 {
-    speed = opt_foreground_rebuild ? 1 << 30 : 50;
     /*
      * If the swap.state file exists in the cache_dir, then
      * we'll use commonUfsDirRebuildFromSwapLog(), otherwise we'll
@@ -345,7 +345,7 @@
     rb->rebuildStep();
 
     if (!rb->isDone())
-        eventAdd("storeRebuild", RebuildStep, rb, 0.0, 1);
+        eventAdd("storeRebuild", RebuildStep, rb, 0.01, 1);
     else {
         StoreController::store_dirs_rebuilding--;
         storeRebuildComplete(&rb->counts);
@@ -353,19 +353,47 @@
     }
 }
 
+/// load entries from swap.state or files until we run out of entries or time
 void
 RebuildState::rebuildStep()
 {
-    if (fromLog)
-        rebuildFromSwapLog();
-    else
-        rebuildFromDirectory();
+    currentEntry(NULL);
+
+    // Balance our desire to maximize the number of entries processed at once
+    // (and, hence, minimize overheads and total rebuild time) with a
+    // requirement to also process Coordinator events, disk I/Os, etc.
+    const int maxSpentMsec = 50; // keep small: most RAM I/Os are under 1ms
+    const timeval loopStart = current_time;
+
+    const int totalEntries = LogParser ? LogParser->SwapLogEntries() : -1;
+
+    while (!isDone()) {
+        if (fromLog)
+            rebuildFromSwapLog();
+        else
+            rebuildFromDirectory();
+
+        // TODO: teach storeRebuildProgress to handle totalEntries <= 0
+        if (totalEntries > 0 && (n_read % 4000 == 0))
+            storeRebuildProgress(sd->index, totalEntries, n_read);
+
+        if (opt_foreground_rebuild)
+            continue; // skip "few entries at a time" check below
+
+        getCurrentTime();
+        const double elapsedMsec = tvSubMsec(loopStart, current_time);
+        if (elapsedMsec > maxSpentMsec || elapsedMsec < 0) {
+            debugs(47, 5, HERE << "pausing after " << n_read << " entries in " <<
+                   elapsedMsec << "ms; " << (elapsedMsec/n_read) << "ms per entry");
+            break;
+        }
+    }
 }
 
+/// process one cache file
 void
 RebuildState::rebuildFromDirectory()
 {
-    currentEntry(NULL);
     cache_key key[SQUID_MD5_DIGEST_LENGTH];
 
     struct stat sb;
@@ -373,68 +401,65 @@
     assert(this != NULL);
     debugs(47, 3, "commonUfsDirRebuildFromDirectory: DIR #" << sd->index);
 
-    for (int count = 0; count < speed; count++) {
-        assert(fd == -1);
-        sfileno filn = 0;
-        int size;
-        fd = getNextFile(&filn, &size);
-
-        if (fd == -2) {
-            debugs(47, 1, "Done scanning " << sd->path << " swaplog (" << n_read << " entries)");
-            _done = true;
-            return;
-        } else if (fd < 0) {
-            continue;
-        }
-
-        assert(fd > -1);
-        /* lets get file stats here */
-
-        if (fstat(fd, &sb) < 0) {
-            debugs(47, 1, "commonUfsDirRebuildFromDirectory: fstat(FD " << fd << "): " << xstrerror());
-            file_close(fd);
-            store_open_disk_fd--;
-            fd = -1;
-            continue;
-        }
+    assert(fd == -1);
+    sfileno filn = 0;
+    int size;
+    fd = getNextFile(&filn, &size);
+
+    if (fd == -2) {
+        debugs(47, 1, "Done scanning " << sd->path << " swaplog (" << n_read << " entries)");
+        _done = true;
+        return;
+    } else if (fd < 0) {
+        return;
+    }
 
-        MemBuf buf;
-        buf.init(SM_PAGE_SIZE, SM_PAGE_SIZE);
-        if (!storeRebuildLoadEntry(fd, sd->index, buf, counts))
-            return;
-
-        StoreEntry tmpe;
-        const bool loaded = storeRebuildParseEntry(buf, tmpe, key, counts,
-                            (int64_t)sb.st_size);
+    assert(fd > -1);
+    /* lets get file stats here */
 
+    if (fstat(fd, &sb) < 0) {
+        debugs(47, 1, "commonUfsDirRebuildFromDirectory: fstat(FD " << fd << "): " << xstrerror());
         file_close(fd);
         store_open_disk_fd--;
         fd = -1;
-
-        if (!loaded) {
-            // XXX: shouldn't this be a call to commonUfsUnlink?
-            sd->unlinkFile(filn); // should we unlink in all failure cases?
-            continue;
-        }
-
-        if (!storeRebuildKeepEntry(tmpe, key, counts))
-            continue;
-
-        counts.objcount++;
-        // tmpe.dump(5);
-        currentEntry(sd->addDiskRestore(key,
-                                        filn,
-                                        tmpe.swap_file_sz,
-                                        tmpe.expires,
-                                        tmpe.timestamp,
-                                        tmpe.lastref,
-                                        tmpe.lastmod,
-                                        tmpe.refcount,	/* refcount */
-                                        tmpe.flags,		/* flags */
-                                        (int) flags.clean));
-        storeDirSwapLog(currentEntry(), SWAP_LOG_ADD);
+        return;
     }
 
+    MemBuf buf;
+    buf.init(SM_PAGE_SIZE, SM_PAGE_SIZE);
+    if (!storeRebuildLoadEntry(fd, sd->index, buf, counts))
+        return;
+
+    StoreEntry tmpe;
+    const bool loaded = storeRebuildParseEntry(buf, tmpe, key, counts,
+                        (int64_t)sb.st_size);
+
+    file_close(fd);
+    store_open_disk_fd--;
+    fd = -1;
+
+    if (!loaded) {
+        // XXX: shouldn't this be a call to commonUfsUnlink?
+        sd->unlinkFile(filn); // should we unlink in all failure cases?
+        return;
+    }
+
+    if (!storeRebuildKeepEntry(tmpe, key, counts))
+        return;
+
+    counts.objcount++;
+    // tmpe.dump(5);
+    currentEntry(sd->addDiskRestore(key,
+                                    filn,
+                                    tmpe.swap_file_sz,
+                                    tmpe.expires,
+                                    tmpe.timestamp,
+                                    tmpe.lastref,
+                                    tmpe.lastmod,
+                                    tmpe.refcount,	/* refcount */
+                                    tmpe.flags,		/* flags */
+                                    (int) flags.clean));
+    storeDirSwapLog(currentEntry(), SWAP_LOG_ADD);
 }
 
 StoreEntry *
@@ -449,115 +474,48 @@
     e = newValue;
 }
 
+/// process one swap log entry
 void
 RebuildState::rebuildFromSwapLog()
 {
-    currentEntry (NULL);
-    double x;
-    /* load a number of objects per invocation */
-
-    for (int count = 0; count < speed; count++) {
-        StoreSwapLogData swapData;
+    StoreSwapLogData swapData;
 
-        if (LogParser->ReadRecord(swapData) != 1) {
-            debugs(47, 1, "Done reading " << sd->path << " swaplog (" << n_read << " entries)");
-            LogParser->Close();
-            delete LogParser;
-            LogParser = NULL;
-            _done = true;
-            return;
-        }
-
-        n_read++;
-
-        if (swapData.op <= SWAP_LOG_NOP)
-            continue;
-
-        if (swapData.op >= SWAP_LOG_MAX)
-            continue;
-
-        /*
-         * BC: during 2.4 development, we changed the way swap file
-         * numbers are assigned and stored.  The high 16 bits used
-         * to encode the SD index number.  There used to be a call
-         * to storeDirProperFileno here that re-assigned the index
-         * bits.  Now, for backwards compatibility, we just need
-         * to mask it off.
-         */
-        swapData.swap_filen &= 0x00FFFFFF;
-
-        debugs(47, 3, "commonUfsDirRebuildFromSwapLog: " <<
-               swap_log_op_str[(int) swapData.op]  << " " <<
-               storeKeyText(swapData.key)  << " "<< std::setfill('0') <<
-               std::hex << std::uppercase << std::setw(8) <<
-               swapData.swap_filen);
-
-        if (swapData.op == SWAP_LOG_ADD) {
-            (void) 0;
-        } else if (swapData.op == SWAP_LOG_DEL) {
-            /* Delete unless we already have a newer copy anywhere in any store */
-            /* this needs to become
-             * 1) unpack url
-             * 2) make synthetic request with headers ?? or otherwise search
-             * for a matching object in the store
-             * TODO FIXME change to new async api
-             */
-            currentEntry (Store::Root().get(swapData.key));
-
-            if (currentEntry() != NULL && swapData.lastref >= e->lastref) {
-                /*
-                 * Make sure we don't unlink the file, it might be
-                 * in use by a subsequent entry.  Also note that
-                 * we don't have to subtract from cur_size because
-                 * adding to cur_size happens in the cleanup procedure.
-                 */
-                currentEntry()->expireNow();
-                currentEntry()->releaseRequest();
-
-                if (currentEntry()->swap_filen > -1) {
-                    UFSSwapDir *sdForThisEntry = dynamic_cast<UFSSwapDir *>(INDEXSD(currentEntry()->swap_dirn));
-                    assert (sdForThisEntry);
-                    sdForThisEntry->replacementRemove(currentEntry());
-                    sdForThisEntry->mapBitReset(currentEntry()->swap_filen);
-                    currentEntry()->swap_filen = -1;
-                    currentEntry()->swap_dirn = -1;
-                }
-
-                currentEntry()->release();
-                counts.objcount--;
-                counts.cancelcount++;
-            }
-            continue;
-        } else {
-            x = ::log(static_cast<double>(++counts.bad_log_op)) / ::log(10.0);
-
-            if (0.0 == x - (double) (int) x)
-                debugs(47, 1, "WARNING: " << counts.bad_log_op << " invalid swap log entries found");
-
-            counts.invalid++;
-
-            continue;
-        }
-
-        if ((++counts.scancount & 0xFFF) == 0) {
-
-            int swap_entries = LogParser->SwapLogEntries();
+    if (LogParser->ReadRecord(swapData) != 1) {
+        debugs(47, 1, "Done reading " << sd->path << " swaplog (" << n_read << " entries)");
+        LogParser->Close();
+        delete LogParser;
+        LogParser = NULL;
+        _done = true;
+        return;
+    }
 
-            if (0 != swap_entries )
-                storeRebuildProgress(sd->index,
-                                     swap_entries, n_read);
-        }
+    n_read++;
 
-        if (!sd->validFileno(swapData.swap_filen, 0)) {
-            counts.invalid++;
-            continue;
-        }
+    if (!swapData.sane()) {
+        counts.invalid++;
+        return;
+    }
 
-        if (EBIT_TEST(swapData.flags, KEY_PRIVATE)) {
-            counts.badflags++;
-            continue;
-        }
+    /*
+     * BC: during 2.4 development, we changed the way swap file
+     * numbers are assigned and stored.  The high 16 bits used
+     * to encode the SD index number.  There used to be a call
+     * to storeDirProperFileno here that re-assigned the index
+     * bits.  Now, for backwards compatibility, we just need
+     * to mask it off.
+     */
+    swapData.swap_filen &= 0x00FFFFFF;
 
+    debugs(47, 3, "commonUfsDirRebuildFromSwapLog: " <<
+           swap_log_op_str[(int) swapData.op]  << " " <<
+           storeKeyText(swapData.key)  << " "<< std::setfill('0') <<
+           std::hex << std::uppercase << std::setw(8) <<
+           swapData.swap_filen);
+
+    if (swapData.op == SWAP_LOG_ADD) {
+        (void) 0;
+    } else if (swapData.op == SWAP_LOG_DEL) {
+        /* Delete unless we already have a newer copy anywhere in any store */
         /* this needs to become
          * 1) unpack url
          * 2) make synthetic request with headers ?? or otherwise search
@@ -566,102 +524,156 @@
          */
         currentEntry (Store::Root().get(swapData.key));
 
-        int used;			/* is swapfile already in use? */
-
-        used = sd->mapBitTest(swapData.swap_filen);
-
-        /* If this URL already exists in the cache, does the swap log
-         * appear to have a newer entry?  Compare 'lastref' from the
-         * swap log to e->lastref. */
-        /* is the log entry newer than current entry? */
-        int disk_entry_newer = currentEntry() ? (swapData.lastref > currentEntry()->lastref ? 1 : 0) : 0;
-
-        if (used && !disk_entry_newer) {
-            /* log entry is old, ignore it */
-            counts.clashcount++;
-            continue;
-        } else if (used && currentEntry() && currentEntry()->swap_filen == swapData.swap_filen && currentEntry()->swap_dirn == sd->index) {
-            /* swapfile taken, same URL, newer, update meta */
-
-            if (currentEntry()->store_status == STORE_OK) {
-                currentEntry()->lastref = swapData.timestamp;
-                currentEntry()->timestamp = swapData.timestamp;
-                currentEntry()->expires = swapData.expires;
-                currentEntry()->lastmod = swapData.lastmod;
-                currentEntry()->flags = swapData.flags;
-                currentEntry()->refcount += swapData.refcount;
-                sd->dereference(*currentEntry());
-            } else {
-                debug_trap("commonUfsDirRebuildFromSwapLog: bad condition");
-                debugs(47, 1, "\tSee " << __FILE__ << ":" << __LINE__);
-            }
-            continue;
-        } else if (used) {
-            /* swapfile in use, not by this URL, log entry is newer */
-            /* This is sorta bad: the log entry should NOT be newer at this
-             * point.  If the log is dirty, the filesize check should have
-             * caught this.  If the log is clean, there should never be a
-             * newer entry. */
-            debugs(47, 1, "WARNING: newer swaplog entry for dirno " <<
-                   sd->index  << ", fileno "<< std::setfill('0') << std::hex <<
-                   std::uppercase << std::setw(8) << swapData.swap_filen);
-
-            /* I'm tempted to remove the swapfile here just to be safe,
-             * but there is a bad race condition in the NOVM version if
-             * the swapfile has recently been opened for writing, but
-             * not yet opened for reading.  Because we can't map
-             * swapfiles back to StoreEntrys, we don't know the state
-             * of the entry using that file.  */
-            /* We'll assume the existing entry is valid, probably because
-             * were in a slow rebuild and the the swap file number got taken
-             * and the validation procedure hasn't run. */
-            assert(flags.need_to_validate);
-            counts.clashcount++;
-            continue;
-        } else if (currentEntry() && !disk_entry_newer) {
-            /* key already exists, current entry is newer */
-            /* keep old, ignore new */
-            counts.dupcount++;
-            continue;
-        } else if (currentEntry()) {
-            /* key already exists, this swapfile not being used */
-            /* junk old, load new */
+        if (currentEntry() != NULL && swapData.lastref >= e->lastref) {
+            /*
+             * Make sure we don't unlink the file, it might be
+             * in use by a subsequent entry.  Also note that
+             * we don't have to subtract from cur_size because
+             * adding to cur_size happens in the cleanup procedure.
+             */
             currentEntry()->expireNow();
             currentEntry()->releaseRequest();
 
             if (currentEntry()->swap_filen > -1) {
                 UFSSwapDir *sdForThisEntry = dynamic_cast<UFSSwapDir *>(INDEXSD(currentEntry()->swap_dirn));
+                assert (sdForThisEntry);
                 sdForThisEntry->replacementRemove(currentEntry());
-                /* Make sure we don't actually unlink the file */
                 sdForThisEntry->mapBitReset(currentEntry()->swap_filen);
                 currentEntry()->swap_filen = -1;
                 currentEntry()->swap_dirn = -1;
             }
 
             currentEntry()->release();
-            counts.dupcount++;
-        } else {
-            /* URL doesnt exist, swapfile not in use */
-            /* load new */
-            (void) 0;
-        }
-
-        counts.objcount++;
-
-        currentEntry(sd->addDiskRestore(swapData.key,
-                                        swapData.swap_filen,
-                                        swapData.swap_file_sz,
-                                        swapData.expires,
-                                        swapData.timestamp,
-                                        swapData.lastref,
-                                        swapData.lastmod,
-                                        swapData.refcount,
-                                        swapData.flags,
-                                        (int) flags.clean));
+            counts.objcount--;
+            counts.cancelcount++;
+        }
+        return;
+    } else {
+        const double
+        x = ::log(static_cast<double>(++counts.bad_log_op)) / ::log(10.0);
+
+        if (0.0 == x - (double) (int) x)
+            debugs(47, 1, "WARNING: " << counts.bad_log_op << " invalid swap log entries found");
+
+        counts.invalid++;
+
+        return;
+    }
 
-        storeDirSwapLog(currentEntry(), SWAP_LOG_ADD);
+    ++counts.scancount; // XXX: should not this be incremented earlier?
+
+    if (!sd->validFileno(swapData.swap_filen, 0)) {
+        counts.invalid++;
+        return;
+    }
+
+    if (EBIT_TEST(swapData.flags, KEY_PRIVATE)) {
+        counts.badflags++;
+        return;
     }
 
+    /* this needs to become
+     * 1) unpack url
+     * 2) make synthetic request with headers ?? or otherwise search
+     * for a matching object in the store
+     * TODO FIXME change to new async api
+     */
+    currentEntry (Store::Root().get(swapData.key));
+
+    int used;			/* is swapfile already in use? */
+
+    used = sd->mapBitTest(swapData.swap_filen);
+
+    /* If this URL already exists in the cache, does the swap log
+     * appear to have a newer entry?  Compare 'lastref' from the
+     * swap log to e->lastref. */
+    /* is the log entry newer than current entry? */
+    int disk_entry_newer = currentEntry() ? (swapData.lastref > currentEntry()->lastref ? 1 : 0) : 0;
+
+    if (used && !disk_entry_newer) {
+        /* log entry is old, ignore it */
+        counts.clashcount++;
+        return;
+    } else if (used && currentEntry() && currentEntry()->swap_filen == swapData.swap_filen && currentEntry()->swap_dirn == sd->index) {
+        /* swapfile taken, same URL, newer, update meta */
+
+        if (currentEntry()->store_status == STORE_OK) {
+            currentEntry()->lastref = swapData.timestamp;
+            currentEntry()->timestamp = swapData.timestamp;
+            currentEntry()->expires = swapData.expires;
+            currentEntry()->lastmod = swapData.lastmod;
+            currentEntry()->flags = swapData.flags;
+            currentEntry()->refcount += swapData.refcount;
+            sd->dereference(*currentEntry());
+        } else {
+            debug_trap("commonUfsDirRebuildFromSwapLog: bad condition");
+            debugs(47, 1, "\tSee " << __FILE__ << ":" << __LINE__);
+        }
+        return;
+    } else if (used) {
+        /* swapfile in use, not by this URL, log entry is newer */
+        /* This is sorta bad: the log entry should NOT be newer at this
+         * point.  If the log is dirty, the filesize check should have
+         * caught this.  If the log is clean, there should never be a
+         * newer entry. */
+        debugs(47, 1, "WARNING: newer swaplog entry for dirno " <<
+               sd->index  << ", fileno "<< std::setfill('0') << std::hex <<
+               std::uppercase << std::setw(8) << swapData.swap_filen);
+
+        /* I'm tempted to remove the swapfile here just to be safe,
+         * but there is a bad race condition in the NOVM version if
+         * the swapfile has recently been opened for writing, but
+         * not yet opened for reading.  Because we can't map
+         * swapfiles back to StoreEntrys, we don't know the state
+         * of the entry using that file.  */
+        /* We'll assume the existing entry is valid, probably because
+         * were in a slow rebuild and the the swap file number got taken
+         * and the validation procedure hasn't run. */
+        assert(flags.need_to_validate);
+        counts.clashcount++;
+        return;
+    } else if (currentEntry() && !disk_entry_newer) {
+        /* key already exists, current entry is newer */
+        /* keep old, ignore new */
+        counts.dupcount++;
+        return;
+    } else if (currentEntry()) {
+        /* key already exists, this swapfile not being used */
+        /* junk old, load new */
+        currentEntry()->expireNow();
+        currentEntry()->releaseRequest();
+
+        if (currentEntry()->swap_filen > -1) {
+            UFSSwapDir *sdForThisEntry = dynamic_cast<UFSSwapDir *>(INDEXSD(currentEntry()->swap_dirn));
+            sdForThisEntry->replacementRemove(currentEntry());
+            /* Make sure we don't actually unlink the file */
+            sdForThisEntry->mapBitReset(currentEntry()->swap_filen);
+            currentEntry()->swap_filen = -1;
+            currentEntry()->swap_dirn = -1;
+        }
+
+        currentEntry()->release();
+        counts.dupcount++;
+    } else {
+        /* URL doesnt exist, swapfile not in use */
+        /* load new */
+        (void) 0;
+    }
+
+    counts.objcount++;
+
+    currentEntry(sd->addDiskRestore(swapData.key,
+                                    swapData.swap_filen,
+                                    swapData.swap_file_sz,
+                                    swapData.expires,
+                                    swapData.timestamp,
+                                    swapData.lastref,
+                                    swapData.lastmod,
+                                    swapData.refcount,
+                                    swapData.flags,
+                                    (int) flags.clean));
+
+    storeDirSwapLog(currentEntry(), SWAP_LOG_ADD);
 }
 
 int
@@ -772,25 +784,6 @@
     return fd;
 }
 
-void
-RebuildState::next(void (aCallback)(void *aCallbackDataarg), void *aCallbackData)
-{
-    /* for now, we don't cache at all */
-    speed = 1;
-    currentEntry(NULL);
-
-    while (!isDone() && currentEntry() == NULL)
-        rebuildStep();
-
-    aCallback(aCallbackData);
-}
-
-bool
-RebuildState::next()
-{
-    return false;
-}
-
 bool
 RebuildState::error() const
 {
diff -u -r -N squid-3.2.0.14/src/fs/ufs/ufscommon.h squid-3.2.0.15/src/fs/ufs/ufscommon.h
--- squid-3.2.0.14/src/fs/ufs/ufscommon.h	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/fs/ufs/ufscommon.h	2012-02-06 04:52:31.000000000 +1300
@@ -372,18 +372,6 @@
     RebuildState(RefCount<UFSSwapDir> sd);
     ~RebuildState();
 
-    /** \todo Iterator API - garh, wrong place */
-    /**
-     * callback the client when a new StoreEntry is available
-     * or an error occurs
-     */
-    virtual void next(void (callback)(void *cbdata), void *cbdata);
-
-    /**
-     \retval true if a new StoreEntry is immediately available
-     \retval false if a new StoreEntry is NOT immediately available
-     */
-    virtual bool next();
     virtual bool error() const;
     virtual bool isDone() const;
     virtual StoreEntry *currentItem();
@@ -392,7 +380,6 @@
     int n_read;
     /*    FILE *log;*/
     UFSSwapLogParser *LogParser;
-    int speed;
     int curlvl1;
     int curlvl2;
 
diff -u -r -N squid-3.2.0.14/src/ftp.cc squid-3.2.0.15/src/ftp.cc
--- squid-3.2.0.14/src/ftp.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/ftp.cc	2012-02-06 04:52:31.000000000 +1300
@@ -32,7 +32,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "comm.h"
 #include "comm/ConnOpener.h"
 #include "CommCalls.h"
diff -u -r -N squid-3.2.0.14/src/gopher.cc squid-3.2.0.15/src/gopher.cc
--- squid-3.2.0.14/src/gopher.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/gopher.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "comm/Write.h"
 #include "errorpage.h"
 #include "Store.h"
diff -u -r -N squid-3.2.0.14/src/helper.cc squid-3.2.0.15/src/helper.cc
--- squid-3.2.0.14/src/helper.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/helper.cc	2012-02-06 04:52:31.000000000 +1300
@@ -32,7 +32,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "base/AsyncCbdataCalls.h"
 #include "comm.h"
 #include "comm/Connection.h"
diff -u -r -N squid-3.2.0.14/src/HelperChildConfig.cc squid-3.2.0.15/src/HelperChildConfig.cc
--- squid-3.2.0.14/src/HelperChildConfig.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/HelperChildConfig.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "config.h"
+#include "squid.h"
 #include "HelperChildConfig.h"
 #include "globals.h"
 
diff -u -r -N squid-3.2.0.14/src/helper.h squid-3.2.0.15/src/helper.h
--- squid-3.2.0.14/src/helper.h	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/helper.h	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
 #ifndef SQUID_HELPER_H
 #define SQUID_HELPER_H
 
-#include "squid.h"
+#include "squid-old.h"
 #include "base/AsyncCall.h"
 #include "cbdata.h"
 #include "comm/forward.h"
diff -u -r -N squid-3.2.0.14/src/htcp.cc squid-3.2.0.15/src/htcp.cc
--- squid-3.2.0.14/src/htcp.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/htcp.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "AccessLogEntry.h"
 #include "acl/FilledChecklist.h"
 #include "acl/Acl.h"
diff -u -r -N squid-3.2.0.14/src/HttpBody.cc squid-3.2.0.15/src/HttpBody.cc
--- squid-3.2.0.14/src/HttpBody.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/HttpBody.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "HttpBody.h"
 #include "MemBuf.h"
 
diff -u -r -N squid-3.2.0.14/src/http.cc squid-3.2.0.15/src/http.cc
--- squid-3.2.0.14/src/http.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/http.cc	2012-02-06 04:52:31.000000000 +1300
@@ -38,7 +38,7 @@
  * have a look into http-anon.c to get more informations.
  */
 
-#include "squid.h"
+#include "squid-old.h"
 
 #include "acl/FilledChecklist.h"
 #if USE_AUTH
diff -u -r -N squid-3.2.0.14/src/HttpHdrCc.cc squid-3.2.0.15/src/HttpHdrCc.cc
--- squid-3.2.0.14/src/HttpHdrCc.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/HttpHdrCc.cc	2012-02-06 04:52:31.000000000 +1300
@@ -30,7 +30,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "base/StringArea.h"
 #include "Store.h"
 #include "HttpHeader.h"
diff -u -r -N squid-3.2.0.14/src/HttpHdrContRange.cc squid-3.2.0.15/src/HttpHdrContRange.cc
--- squid-3.2.0.14/src/HttpHdrContRange.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/HttpHdrContRange.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "HttpHdrContRange.h"
 
 /*
diff -u -r -N squid-3.2.0.14/src/HttpHdrRange.cc squid-3.2.0.15/src/HttpHdrRange.cc
--- squid-3.2.0.14/src/HttpHdrRange.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/HttpHdrRange.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "Store.h"
 #include "HttpHeaderRange.h"
 #include "client_side_request.h"
diff -u -r -N squid-3.2.0.14/src/HttpHdrSc.cc squid-3.2.0.15/src/HttpHdrSc.cc
--- squid-3.2.0.14/src/HttpHdrSc.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/HttpHdrSc.cc	2012-02-06 04:52:31.000000000 +1300
@@ -36,7 +36,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "Store.h"
 #include "HttpHeader.h"
 #include "HttpHdrSc.h"
diff -u -r -N squid-3.2.0.14/src/HttpHdrScTarget.cc squid-3.2.0.15/src/HttpHdrScTarget.cc
--- squid-3.2.0.14/src/HttpHdrScTarget.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/HttpHdrScTarget.cc	2012-02-06 04:52:31.000000000 +1300
@@ -35,7 +35,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "HttpHdrSc.h"
 
 extern http_hdr_sc_type &operator++ (http_hdr_sc_type &aHeader);
diff -u -r -N squid-3.2.0.14/src/HttpHeader.cc squid-3.2.0.15/src/HttpHeader.cc
--- squid-3.2.0.14/src/HttpHeader.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/HttpHeader.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "base64.h"
 #include "HttpHdrContRange.h"
 #include "HttpHdrCc.h"
@@ -114,6 +114,7 @@
     {"Max-Forwards", HDR_MAX_FORWARDS, ftInt64},
     {"Mime-Version", HDR_MIME_VERSION, ftStr},	/* for now */
     {"Negotiate", HDR_NEGOTIATE, ftStr},
+    {"Origin", HDR_ORIGIN, ftStr},
     {"Pragma", HDR_PRAGMA, ftStr},
     {"Proxy-Authenticate", HDR_PROXY_AUTHENTICATE, ftStr},
     {"Proxy-Authentication-Info", HDR_PROXY_AUTHENTICATION_INFO, ftStr},
@@ -229,6 +230,7 @@
     HDR_ACCEPT_RANGES, HDR_AGE,
     HDR_LOCATION, HDR_MAX_FORWARDS,
     HDR_MIME_VERSION, HDR_PUBLIC, HDR_RETRY_AFTER, HDR_SERVER, HDR_SET_COOKIE, HDR_SET_COOKIE2,
+    HDR_ORIGIN,
     HDR_VARY,
     HDR_WARNING, HDR_PROXY_CONNECTION, HDR_X_CACHE,
     HDR_X_CACHE_LOOKUP,
@@ -247,7 +249,9 @@
 static http_hdr_type RequestHeadersArr[] = {
     HDR_AUTHORIZATION, HDR_FROM, HDR_HOST,
     HDR_IF_MATCH, HDR_IF_MODIFIED_SINCE, HDR_IF_NONE_MATCH,
-    HDR_IF_RANGE, HDR_MAX_FORWARDS, HDR_PROXY_CONNECTION,
+    HDR_IF_RANGE, HDR_MAX_FORWARDS,
+    HDR_ORIGIN,
+    HDR_PROXY_CONNECTION,
     HDR_PROXY_AUTHORIZATION, HDR_RANGE, HDR_REFERER, HDR_REQUEST_RANGE,
     HDR_USER_AGENT, HDR_X_FORWARDED_FOR, HDR_SURROGATE_CAPABILITY
 };
diff -u -r -N squid-3.2.0.14/src/HttpHeader.h squid-3.2.0.15/src/HttpHeader.h
--- squid-3.2.0.14/src/HttpHeader.h	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/HttpHeader.h	2012-02-06 04:52:31.000000000 +1300
@@ -101,6 +101,7 @@
     HDR_MIME_VERSION,                   /**< RFC 2626 */
     HDR_NEGOTIATE,                      /**< experimental RFC 2295. Why only this one from 2295? */
     /*HDR_OVERWRITE,*/                  /* RFC 2518 */
+    HDR_ORIGIN,                         /* CORS Draft specification (see http://www.w3.org/TR/cors/) */
     HDR_PRAGMA,                         /**< deprecated RFC 2068,2616 header we may need to erase */
     HDR_PROXY_AUTHENTICATE,             /**< RFC 2608, 2616, 2617 */
     HDR_PROXY_AUTHENTICATION_INFO,      /**< RFC 2617 */
diff -u -r -N squid-3.2.0.14/src/HttpHeaderTools.cc squid-3.2.0.15/src/HttpHeaderTools.cc
--- squid-3.2.0.14/src/HttpHeaderTools.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/HttpHeaderTools.cc	2012-02-06 04:52:31.000000000 +1300
@@ -32,7 +32,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "acl/FilledChecklist.h"
 #include "compat/strtoll.h"
 #include "HttpHdrContRange.h"
diff -u -r -N squid-3.2.0.14/src/HttpMsg.cc squid-3.2.0.15/src/HttpMsg.cc
--- squid-3.2.0.14/src/HttpMsg.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/HttpMsg.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "HttpMsg.h"
 #include "MemBuf.h"
 
diff -u -r -N squid-3.2.0.14/src/HttpParser.cc squid-3.2.0.15/src/HttpParser.cc
--- squid-3.2.0.14/src/HttpParser.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/HttpParser.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "config.h"
+#include "squid.h"
 #include "Debug.h"
 #include "HttpParser.h"
 #include "structs.h"
diff -u -r -N squid-3.2.0.14/src/HttpReply.cc squid-3.2.0.15/src/HttpReply.cc
--- squid-3.2.0.14/src/HttpReply.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/HttpReply.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "SquidTime.h"
 #include "Store.h"
 #include "HttpBody.h"
diff -u -r -N squid-3.2.0.14/src/HttpRequest.cc squid-3.2.0.15/src/HttpRequest.cc
--- squid-3.2.0.14/src/HttpRequest.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/HttpRequest.cc	2012-02-06 04:52:31.000000000 +1300
@@ -34,7 +34,7 @@
  * Copyright (c) 2003, Robert Collins <robertc@squid-cache.org>
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "DnsLookupDetails.h"
 #include "HttpRequest.h"
 #include "HttpHdrCc.h"
@@ -605,6 +605,13 @@
 bool
 HttpRequest::cacheable() const
 {
+    // Intercepted request with Host: header which cannot be trusted.
+    // Because it failed verification, or someone bypassed the security tests
+    // we cannot cache the reponse for sharing between clients.
+    // TODO: update cache to store for particular clients only (going to same Host: and destination IP)
+    if (!flags.hostVerified && (flags.intercepted || flags.spoof_client_ip))
+        return false;
+
     if (protocol == AnyP::PROTO_HTTP)
         return httpCachable(method);
 
diff -u -r -N squid-3.2.0.14/src/HttpRequest.h squid-3.2.0.15/src/HttpRequest.h
--- squid-3.2.0.14/src/HttpRequest.h	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/HttpRequest.h	2012-02-06 04:52:31.000000000 +1300
@@ -146,7 +146,7 @@
 public:
     Ip::Address host_addr;
 #if USE_AUTH
-    AuthUserRequest::Pointer auth_user_request;
+    Auth::UserRequest::Pointer auth_user_request;
 #endif
     unsigned short port;
 
diff -u -r -N squid-3.2.0.14/src/HttpRequestMethod.cc squid-3.2.0.15/src/HttpRequestMethod.cc
--- squid-3.2.0.14/src/HttpRequestMethod.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/HttpRequestMethod.cc	2012-02-06 04:52:31.000000000 +1300
@@ -34,7 +34,7 @@
  * Copyright (c) 2003, Robert Collins <robertc@squid-cache.org>
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "HttpRequestMethod.h"
 #include "wordlist.h"
 
diff -u -r -N squid-3.2.0.14/src/HttpRequestMethod.h squid-3.2.0.15/src/HttpRequestMethod.h
--- squid-3.2.0.14/src/HttpRequestMethod.h	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/HttpRequestMethod.h	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
 #ifndef SQUID_HTTPREQUESTMETHOD_H
 #define SQUID_HTTPREQUESTMETHOD_H
 
-#include "squid.h"
+#include "squid-old.h"
 #include <iosfwd>
 #include "SquidString.h"
 
diff -u -r -N squid-3.2.0.14/src/HttpStatusLine.cc squid-3.2.0.15/src/HttpStatusLine.cc
--- squid-3.2.0.14/src/HttpStatusLine.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/HttpStatusLine.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "HttpStatusLine.h"
 
 /* local constants */
diff -u -r -N squid-3.2.0.14/src/icmp/Icmp4.cc squid-3.2.0.15/src/icmp/Icmp4.cc
--- squid-3.2.0.14/src/icmp/Icmp4.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/icmp/Icmp4.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
  */
 //#define SQUID_HELPER 1
 
-#include "squid.h"
+#include "squid-old.h"
 
 #if USE_ICMP
 
diff -u -r -N squid-3.2.0.14/src/icmp/Icmp6.cc squid-3.2.0.15/src/icmp/Icmp6.cc
--- squid-3.2.0.14/src/icmp/Icmp6.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/icmp/Icmp6.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
  */
 //#define SQUID_HELPER 1
 
-#include "squid.h"
+#include "squid-old.h"
 
 #if USE_ICMP
 
diff -u -r -N squid-3.2.0.14/src/icmp/Icmp.cc squid-3.2.0.15/src/icmp/Icmp.cc
--- squid-3.2.0.14/src/icmp/Icmp.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/icmp/Icmp.cc	2012-02-06 04:52:31.000000000 +1300
@@ -31,7 +31,7 @@
  *  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111, USA.
  *
  */
-#include "squid.h"
+#include "squid-old.h"
 #include "Icmp.h"
 #include "SquidTime.h"
 #include "Debug.h"
diff -u -r -N squid-3.2.0.14/src/icmp/IcmpPinger.cc squid-3.2.0.15/src/icmp/IcmpPinger.cc
--- squid-3.2.0.14/src/icmp/IcmpPinger.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/icmp/IcmpPinger.cc	2012-02-06 04:52:31.000000000 +1300
@@ -34,7 +34,7 @@
 
 #define SQUID_HELPER 1
 
-#include "squid.h"
+#include "squid-old.h"
 
 #if USE_ICMP
 
diff -u -r -N squid-3.2.0.14/src/icmp/IcmpSquid.cc squid-3.2.0.15/src/icmp/IcmpSquid.cc
--- squid-3.2.0.14/src/icmp/IcmpSquid.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/icmp/IcmpSquid.cc	2012-02-06 04:52:31.000000000 +1300
@@ -32,7 +32,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "comm.h"
 #include "comm/Loops.h"
 #include "icmp/IcmpSquid.h"
@@ -250,7 +250,7 @@
 
     Comm::SetSelect(icmp_sock, COMM_SELECT_READ, icmpSquidRecv, NULL, 0);
 
-    commSetTimeout(icmp_sock, -1, NULL, NULL);
+    commUnsetFdTimeout(icmp_sock);
 
     debugs(37, 1, HERE << "Pinger socket opened on FD " << icmp_sock);
 
diff -u -r -N squid-3.2.0.14/src/icmp/net_db.cc squid-3.2.0.15/src/icmp/net_db.cc
--- squid-3.2.0.14/src/icmp/net_db.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/icmp/net_db.cc	2012-02-06 04:52:31.000000000 +1300
@@ -38,7 +38,7 @@
  * (adrian@squid-cache.org) to sort them out.
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "icmp/net_db.h"
 #include "log/File.h"
 #include "cbdata.h"
diff -u -r -N squid-3.2.0.14/src/icmp/pinger.cc squid-3.2.0.15/src/icmp/pinger.cc
--- squid-3.2.0.14/src/icmp/pinger.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/icmp/pinger.cc	2012-02-06 04:52:31.000000000 +1300
@@ -63,7 +63,7 @@
  *      ICP_OP_MISS_NOFETCH for sites which it cannot ping.
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "SquidTime.h"
 
 #if USE_ICMP
diff -u -r -N squid-3.2.0.14/src/icmp/testIcmp.cc squid-3.2.0.15/src/icmp/testIcmp.cc
--- squid-3.2.0.14/src/icmp/testIcmp.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/icmp/testIcmp.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,7 +1,7 @@
 #define SQUID_UNIT_TEST 1
 #define SQUID_HELPER 1
 
-#include "squid.h"
+#include "squid-old.h"
 
 #include <cppunit/TestAssert.h>
 
diff -u -r -N squid-3.2.0.14/src/icp_v2.cc squid-3.2.0.15/src/icp_v2.cc
--- squid-3.2.0.14/src/icp_v2.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/icp_v2.cc	2012-02-06 04:52:31.000000000 +1300
@@ -35,7 +35,7 @@
  \ingroup ServerProtocolICPAPI
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "Store.h"
 #include "comm.h"
 #include "comm/Loops.h"
diff -u -r -N squid-3.2.0.14/src/icp_v3.cc squid-3.2.0.15/src/icp_v3.cc
--- squid-3.2.0.14/src/icp_v3.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/icp_v3.cc	2012-02-06 04:52:31.000000000 +1300
@@ -37,7 +37,7 @@
  \ingroup ServerProtocolICPAPI
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "Store.h"
 #include "ICP.h"
 #include "HttpRequest.h"
diff -u -r -N squid-3.2.0.14/src/ident/AclIdent.cc squid-3.2.0.15/src/ident/AclIdent.cc
--- squid-3.2.0.14/src/ident/AclIdent.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/ident/AclIdent.cc	2012-02-06 04:52:31.000000000 +1300
@@ -34,7 +34,7 @@
  * Copyright (c) 2003, Robert Collins <robertc@squid-cache.org>
  */
 
-#include "squid.h"
+#include "squid-old.h"
 
 #if USE_IDENT
 
diff -u -r -N squid-3.2.0.14/src/ident/Ident.cc squid-3.2.0.15/src/ident/Ident.cc
--- squid-3.2.0.14/src/ident/Ident.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/ident/Ident.cc	2012-02-06 04:52:31.000000000 +1300
@@ -32,7 +32,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 
 #if USE_IDENT
 
diff -u -r -N squid-3.2.0.14/src/int.cc squid-3.2.0.15/src/int.cc
--- squid-3.2.0.14/src/int.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/int.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 int
 isPowTen(int count)
 {
diff -u -r -N squid-3.2.0.14/src/internal.cc squid-3.2.0.15/src/internal.cc
--- squid-3.2.0.14/src/internal.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/internal.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "CacheManager.h"
 #include "comm/Connection.h"
 #include "errorpage.h"
diff -u -r -N squid-3.2.0.14/src/ip/Address.cc squid-3.2.0.15/src/ip/Address.cc
--- squid-3.2.0.14/src/ip/Address.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/ip/Address.cc	2012-02-06 04:52:31.000000000 +1300
@@ -34,7 +34,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 #include "compat/inet_ntop.h"
 #include "compat/getaddrinfo.h"
 #include "Debug.h"
diff -u -r -N squid-3.2.0.14/src/ip/Intercept.cc squid-3.2.0.15/src/ip/Intercept.cc
--- squid-3.2.0.14/src/ip/Intercept.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/ip/Intercept.cc	2012-02-06 04:52:31.000000000 +1300
@@ -30,7 +30,7 @@
  *  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111, USA.
  *
  */
-#include "config.h"
+#include "squid.h"
 #include "comm/Connection.h"
 #include "ip/Intercept.h"
 #include "fde.h"
@@ -184,28 +184,18 @@
 {
 #if IPF_TRANSPARENT  /* --enable-ipf-transparent */
 
-#if defined(IPFILTER_VERSION) && (IPFILTER_VERSION >= 4000027)
-    struct ipfobj obj;
-#else
-    static int siocgnatl_cmd = SIOCGNATL & 0xff;
-#endif
     struct natlookup natLookup;
     static int natfd = -1;
     int x;
 
-#if defined(IPFILTER_VERSION) && (IPFILTER_VERSION >= 4000027)
-
-    obj.ipfo_rev = IPFILTER_VERSION;
-    obj.ipfo_size = sizeof(natLookup);
-    obj.ipfo_ptr = &natLookup;
-    obj.ipfo_type = IPFOBJ_NATLOOKUP;
-    obj.ipfo_offset = 0;
-#endif
-
+    // all fields must be set to 0
+    memset(&natLookup, 0, sizeof(natLookup));
+    // for NAT lookup set local and remote IP:port's
     natLookup.nl_inport = htons(newConn->local.GetPort());
     newConn->local.GetInAddr(natLookup.nl_inip);
     natLookup.nl_outport = htons(newConn->remote.GetPort());
     newConn->remote.GetInAddr(natLookup.nl_outip);
+    // ... and the TCP flag
     natLookup.nl_flags = IPN_TCP;
 
     if (natfd < 0) {
@@ -223,13 +213,20 @@
 
     if (natfd < 0) {
         if (!silent) {
-            debugs(89, DBG_IMPORTANT, HERE << "NAT open failed: " << xstrerror());
+            debugs(89, DBG_IMPORTANT, "IPF (IPFilter) NAT open failed: " << xstrerror());
             lastReported_ = squid_curtime;
             return false;
         }
     }
 
 #if defined(IPFILTER_VERSION) && (IPFILTER_VERSION >= 4000027)
+    struct ipfobj obj;
+    memset(&obj, 0, sizeof(obj));
+    obj.ipfo_rev = IPFILTER_VERSION;
+    obj.ipfo_size = sizeof(natLookup);
+    obj.ipfo_ptr = &natLookup;
+    obj.ipfo_type = IPFOBJ_NATLOOKUP;
+
     x = ioctl(natfd, SIOCGNATL, &obj);
 #else
     /*
@@ -239,6 +236,7 @@
     * put something in configure and use ifdefs here, but
     * this seems simpler.
     */
+    static int siocgnatl_cmd = SIOCGNATL & 0xff;
     if (63 == siocgnatl_cmd) {
         struct natlookup *nlp = &natLookup;
         x = ioctl(natfd, SIOCGNATL, &nlp);
@@ -250,7 +248,7 @@
     if (x < 0) {
         if (errno != ESRCH) {
             if (!silent) {
-                debugs(89, DBG_IMPORTANT, HERE << "NAT lookup failed: ioctl(SIOCGNATL)");
+                debugs(89, DBG_IMPORTANT, "IPF (IPFilter) NAT lookup failed: ioctl(SIOCGNATL) (v=" << IPFILTER_VERSION << "): " << xstrerror());
                 lastReported_ = squid_curtime;
             }
 
diff -u -r -N squid-3.2.0.14/src/ip/QosConfig.cc squid-3.2.0.15/src/ip/QosConfig.cc
--- squid-3.2.0.14/src/ip/QosConfig.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/ip/QosConfig.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "squid.h"
+#include "squid-old.h"
 
 #include "acl/Gadgets.h"
 #include "comm/Connection.h"
diff -u -r -N squid-3.2.0.14/src/ip/testAddress.cc squid-3.2.0.15/src/ip/testAddress.cc
--- squid-3.2.0.14/src/ip/testAddress.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/ip/testAddress.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,5 +1,5 @@
 #define SQUID_UNIT_TEST 1
-#include "config.h"
+#include "squid.h"
 //#include "compat/getaddrinfo.h"
 #include "testAddress.h"
 #include "ip/Address.h"
diff -u -r -N squid-3.2.0.14/src/ip/tools.cc squid-3.2.0.15/src/ip/tools.cc
--- squid-3.2.0.14/src/ip/tools.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/ip/tools.cc	2012-02-06 04:52:31.000000000 +1300
@@ -30,7 +30,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 #include "Debug.h"
 #include "ip/tools.h"
 
diff -u -r -N squid-3.2.0.14/src/ipc/AtomicWord.cc squid-3.2.0.15/src/ipc/AtomicWord.cc
--- squid-3.2.0.14/src/ipc/AtomicWord.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/ipc/AtomicWord.cc	2012-02-06 04:52:31.000000000 +1300
@@ -5,7 +5,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 #include "ipc/AtomicWord.h"
 #include "protos.h"
 
diff -u -r -N squid-3.2.0.14/src/ipc/Coordinator.cc squid-3.2.0.15/src/ipc/Coordinator.cc
--- squid-3.2.0.14/src/ipc/Coordinator.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/ipc/Coordinator.cc	2012-02-06 04:52:31.000000000 +1300
@@ -6,7 +6,7 @@
  */
 
 
-#include "config.h"
+#include "squid.h"
 #include "base/Subscription.h"
 #include "base/TextException.h"
 #include "CacheManager.h"
diff -u -r -N squid-3.2.0.14/src/ipc/FdNotes.cc squid-3.2.0.15/src/ipc/FdNotes.cc
--- squid-3.2.0.14/src/ipc/FdNotes.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/ipc/FdNotes.cc	2012-02-06 04:52:31.000000000 +1300
@@ -5,7 +5,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 #include "Debug.h"
 #include "ipc/FdNotes.h"
 
diff -u -r -N squid-3.2.0.14/src/ipc/Forwarder.cc squid-3.2.0.15/src/ipc/Forwarder.cc
--- squid-3.2.0.14/src/ipc/Forwarder.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/ipc/Forwarder.cc	2012-02-06 04:52:31.000000000 +1300
@@ -5,7 +5,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 #include "base/AsyncJobCalls.h"
 #include "base/TextException.h"
 #include "errorpage.h"
diff -u -r -N squid-3.2.0.14/src/ipc/Inquirer.cc squid-3.2.0.15/src/ipc/Inquirer.cc
--- squid-3.2.0.14/src/ipc/Inquirer.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/ipc/Inquirer.cc	2012-02-06 04:52:31.000000000 +1300
@@ -5,7 +5,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 #include "base/TextException.h"
 #include "comm.h"
 #include "comm/Write.h"
diff -u -r -N squid-3.2.0.14/src/ipc/Kid.cc squid-3.2.0.15/src/ipc/Kid.cc
--- squid-3.2.0.14/src/ipc/Kid.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/ipc/Kid.cc	2012-02-06 04:52:31.000000000 +1300
@@ -5,7 +5,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 #include "globals.h"
 #include "ipc/Kid.h"
 
diff -u -r -N squid-3.2.0.14/src/ipc/Kids.cc squid-3.2.0.15/src/ipc/Kids.cc
--- squid-3.2.0.14/src/ipc/Kids.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/ipc/Kids.cc	2012-02-06 04:52:31.000000000 +1300
@@ -5,7 +5,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 #include "base/TextException.h"
 #include "ipc/Kids.h"
 #include "protos.h"
diff -u -r -N squid-3.2.0.14/src/ipc/mem/Page.cc squid-3.2.0.15/src/ipc/mem/Page.cc
--- squid-3.2.0.14/src/ipc/mem/Page.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/ipc/mem/Page.cc	2012-02-06 04:52:31.000000000 +1300
@@ -5,7 +5,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 #include "ipc/mem/Page.h"
 
 #if HAVE_IOSTREAM
diff -u -r -N squid-3.2.0.14/src/ipc/mem/PagePool.cc squid-3.2.0.15/src/ipc/mem/PagePool.cc
--- squid-3.2.0.14/src/ipc/mem/PagePool.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/ipc/mem/PagePool.cc	2012-02-06 04:52:31.000000000 +1300
@@ -5,7 +5,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 #include "base/TextException.h"
 #include "ipc/mem/Page.h"
 #include "ipc/mem/PagePool.h"
diff -u -r -N squid-3.2.0.14/src/ipc/mem/Pages.cc squid-3.2.0.15/src/ipc/mem/Pages.cc
--- squid-3.2.0.14/src/ipc/mem/Pages.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/ipc/mem/Pages.cc	2012-02-06 04:52:31.000000000 +1300
@@ -5,7 +5,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 #include "base/TextException.h"
 #include "base/RunnersRegistry.h"
 #include "ipc/mem/PagePool.h"
diff -u -r -N squid-3.2.0.14/src/ipc/mem/PageStack.cc squid-3.2.0.15/src/ipc/mem/PageStack.cc
--- squid-3.2.0.14/src/ipc/mem/PageStack.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/ipc/mem/PageStack.cc	2012-02-06 04:52:31.000000000 +1300
@@ -5,7 +5,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 
 #include "base/TextException.h"
 #include "ipc/mem/Page.h"
diff -u -r -N squid-3.2.0.14/src/ipc/mem/Segment.cc squid-3.2.0.15/src/ipc/mem/Segment.cc
--- squid-3.2.0.14/src/ipc/mem/Segment.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/ipc/mem/Segment.cc	2012-02-06 04:52:31.000000000 +1300
@@ -5,7 +5,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 #include "base/TextException.h"
 #include "compat/shm.h"
 #include "ipc/mem/Segment.h"
@@ -178,9 +178,15 @@
 String
 Ipc::Mem::Segment::GenerateName(const char *id)
 {
-    assert(BasePath);
+    assert(BasePath && *BasePath);
     static const bool nameIsPath = shm_portable_segment_name_is_path();
-    String name(nameIsPath ? BasePath : "/squid-");
+    String name;
+    if (nameIsPath) {
+        name.append(BasePath);
+        if (name[name.size()-1] != '/')
+            name.append('/');
+    } else
+        name.append("/squid-");
 
     // append id, replacing slashes with dots
     for (const char *slash = strchr(id, '/'); slash; slash = strchr(id, '/')) {
diff -u -r -N squid-3.2.0.14/src/ipc/Port.cc squid-3.2.0.15/src/ipc/Port.cc
--- squid-3.2.0.14/src/ipc/Port.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/ipc/Port.cc	2012-02-06 04:52:31.000000000 +1300
@@ -6,7 +6,7 @@
  */
 
 
-#include "config.h"
+#include "squid.h"
 #include "comm.h"
 #include "CommCalls.h"
 #include "comm/Connection.h"
diff -u -r -N squid-3.2.0.14/src/ipc/Queue.cc squid-3.2.0.15/src/ipc/Queue.cc
--- squid-3.2.0.14/src/ipc/Queue.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/ipc/Queue.cc	2012-02-06 04:52:31.000000000 +1300
@@ -5,7 +5,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 #include "base/TextException.h"
 #include "Debug.h"
 #include "globals.h"
diff -u -r -N squid-3.2.0.14/src/ipc/ReadWriteLock.cc squid-3.2.0.15/src/ipc/ReadWriteLock.cc
--- squid-3.2.0.14/src/ipc/ReadWriteLock.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/ipc/ReadWriteLock.cc	2012-02-06 04:52:31.000000000 +1300
@@ -4,7 +4,7 @@
  * DEBUG: section 54    Interprocess Communication
  */
 
-#include "squid.h"
+#include "squid-old.h"
 
 #include "Store.h"
 #include "ipc/ReadWriteLock.h"
diff -u -r -N squid-3.2.0.14/src/ipc/SharedListen.cc squid-3.2.0.15/src/ipc/SharedListen.cc
--- squid-3.2.0.14/src/ipc/SharedListen.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/ipc/SharedListen.cc	2012-02-06 04:52:31.000000000 +1300
@@ -5,7 +5,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 #include <map>
 #include "comm.h"
 #include "base/TextException.h"
diff -u -r -N squid-3.2.0.14/src/ipc/StartListening.cc squid-3.2.0.15/src/ipc/StartListening.cc
--- squid-3.2.0.14/src/ipc/StartListening.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/ipc/StartListening.cc	2012-02-06 04:52:31.000000000 +1300
@@ -5,7 +5,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 #include "base/TextException.h"
 #include "comm.h"
 #include "comm/Connection.h"
diff -u -r -N squid-3.2.0.14/src/ipc/StoreMap.cc squid-3.2.0.15/src/ipc/StoreMap.cc
--- squid-3.2.0.14/src/ipc/StoreMap.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/ipc/StoreMap.cc	2012-02-06 04:52:31.000000000 +1300
@@ -4,7 +4,7 @@
  * DEBUG: section 54    Interprocess Communication
  */
 
-#include "squid.h"
+#include "squid-old.h"
 
 #include "Store.h"
 #include "ipc/StoreMap.h"
diff -u -r -N squid-3.2.0.14/src/ipc/Strand.cc squid-3.2.0.15/src/ipc/Strand.cc
--- squid-3.2.0.14/src/ipc/Strand.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/ipc/Strand.cc	2012-02-06 04:52:31.000000000 +1300
@@ -5,7 +5,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 #include "base/Subscription.h"
 #include "base/TextException.h"
 #include "comm/Connection.h"
diff -u -r -N squid-3.2.0.14/src/ipc/StrandCoord.cc squid-3.2.0.15/src/ipc/StrandCoord.cc
--- squid-3.2.0.14/src/ipc/StrandCoord.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/ipc/StrandCoord.cc	2012-02-06 04:52:31.000000000 +1300
@@ -6,7 +6,7 @@
  */
 
 
-#include "config.h"
+#include "squid.h"
 #include "Debug.h"
 #include "ipc/Messages.h"
 #include "ipc/StrandCoord.h"
diff -u -r -N squid-3.2.0.14/src/ipc/StrandSearch.cc squid-3.2.0.15/src/ipc/StrandSearch.cc
--- squid-3.2.0.14/src/ipc/StrandSearch.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/ipc/StrandSearch.cc	2012-02-06 04:52:31.000000000 +1300
@@ -6,7 +6,7 @@
  */
 
 
-#include "config.h"
+#include "squid.h"
 #include "ipc/Messages.h"
 #include "ipc/StrandSearch.h"
 #include "ipc/TypedMsgHdr.h"
diff -u -r -N squid-3.2.0.14/src/ipc/TypedMsgHdr.cc squid-3.2.0.15/src/ipc/TypedMsgHdr.cc
--- squid-3.2.0.14/src/ipc/TypedMsgHdr.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/ipc/TypedMsgHdr.cc	2012-02-06 04:52:31.000000000 +1300
@@ -6,7 +6,7 @@
  */
 
 
-#include "config.h"
+#include "squid.h"
 #include <string.h>
 #include "protos.h"
 #include "base/TextException.h"
diff -u -r -N squid-3.2.0.14/src/ipc/UdsOp.cc squid-3.2.0.15/src/ipc/UdsOp.cc
--- squid-3.2.0.14/src/ipc/UdsOp.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/ipc/UdsOp.cc	2012-02-06 04:52:31.000000000 +1300
@@ -6,7 +6,7 @@
  */
 
 
-#include "config.h"
+#include "squid.h"
 #include "comm.h"
 #include "CommCalls.h"
 #include "comm/Connection.h"
diff -u -r -N squid-3.2.0.14/src/ipcache.cc squid-3.2.0.15/src/ipcache.cc
--- squid-3.2.0.14/src/ipcache.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/ipcache.cc	2012-02-06 04:52:31.000000000 +1300
@@ -30,7 +30,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "cbdata.h"
 #include "CacheManager.h"
 #include "DnsLookupDetails.h"
@@ -39,6 +39,7 @@
 #include "ip/tools.h"
 #include "ipcache.h"
 #include "mgr/Registration.h"
+#include "SquidDns.h"
 #include "SquidTime.h"
 #include "Store.h"
 #include "wordlist.h"
@@ -133,13 +134,13 @@
 static void stat_ipcache_get(StoreEntry *);
 
 static FREE ipcacheFreeEntry;
-#if USE_DNSSERVERS
+#if USE_DNSHELPER
 static HLPCB ipcacheHandleReply;
 #else
 static IDNSCB ipcacheHandleReply;
 #endif
 static int ipcacheExpiredEntry(ipcache_entry *);
-#if USE_DNSSERVERS
+#if USE_DNSHELPER
 static int ipcacheParse(ipcache_entry *, const char *buf);
 #else
 static int ipcacheParse(ipcache_entry *, rfc1035_rr *, int, const char *error);
@@ -351,7 +352,7 @@
 }
 
 /// \ingroup IPCacheAPI
-#if USE_DNSSERVERS
+#if USE_DNSHELPER
 static int
 ipcacheParse(ipcache_entry *i, const char *inbuf)
 {
@@ -587,7 +588,7 @@
 
 /// \ingroup IPCacheInternal
 static void
-#if USE_DNSSERVERS
+#if USE_DNSHELPER
 ipcacheHandleReply(void *data, char *reply)
 #else
 ipcacheHandleReply(void *data, rfc1035_rr * answers, int na, const char *error_message)
@@ -599,7 +600,7 @@
     const int age = i->age();
     statHistCount(&statCounter.dns.svc_time, age);
 
-#if USE_DNSSERVERS
+#if USE_DNSHELPER
     ipcacheParse(i, reply);
 #else
 
@@ -692,11 +693,9 @@
     i->handlerData = cbdataReference(handlerData);
     i->request_time = current_time;
     c = new generic_cbdata(i);
-#if USE_DNSSERVERS
-
+#if USE_DNSHELPER
     dnsSubmit(hashKeyStr(&i->hash), ipcacheHandleReply, c);
 #else
-
     idnsALookup(hashKeyStr(&i->hash), ipcacheHandleReply, c);
 #endif
 }
diff -u -r -N squid-3.2.0.14/src/ipc.cc squid-3.2.0.15/src/ipc.cc
--- squid-3.2.0.14/src/ipc.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/ipc.cc	2012-02-06 04:52:31.000000000 +1300
@@ -30,7 +30,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "comm/Connection.h"
 #include "fde.h"
 #include "ip/Address.h"
@@ -268,7 +268,7 @@
             return ipcCloseAllFD(prfd, pwfd, crfd, cwfd);
         }
 
-        commSetTimeout(prfd, -1, NULL, NULL);
+        commUnsetFdTimeout(prfd);
         commSetNonBlocking(prfd);
         commSetNonBlocking(pwfd);
 
diff -u -r -N squid-3.2.0.14/src/ipc_win32.cc squid-3.2.0.15/src/ipc_win32.cc
--- squid-3.2.0.14/src/ipc_win32.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/ipc_win32.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "comm.h"
 #include "fde.h"
 #include "ip/Address.h"
@@ -303,7 +303,7 @@
 
     hello_buf[x] = '\0';
     pid = atol(hello_buf);
-    commSetTimeout(prfd, -1, NULL, NULL);
+    commUnsetFdTimeout(prfd);
     commSetNonBlocking(prfd);
     commSetNonBlocking(pwfd);
     commSetCloseOnExec(prfd);
diff -u -r -N squid-3.2.0.14/src/LeakFinder.cc squid-3.2.0.15/src/LeakFinder.cc
--- squid-3.2.0.14/src/LeakFinder.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/LeakFinder.cc	2012-02-06 04:52:31.000000000 +1300
@@ -36,7 +36,7 @@
  * Use these to find memory leaks
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "LeakFinder.h"
 #include "Store.h"
 #include "SquidTime.h"
diff -u -r -N squid-3.2.0.14/src/list.cc squid-3.2.0.15/src/list.cc
--- squid-3.2.0.14/src/list.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/list.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 
 /* This should go away, in favour of the List template class */
 
diff -u -r -N squid-3.2.0.14/src/LoadableModule.cc squid-3.2.0.15/src/LoadableModule.cc
--- squid-3.2.0.14/src/LoadableModule.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/LoadableModule.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "squid.h"
+#include "squid-old.h"
 
 /* The original code has this constant ./configure-able.
  * The "#else" branches use raw dlopen interface and have not been tested.
diff -u -r -N squid-3.2.0.14/src/LoadableModules.cc squid-3.2.0.15/src/LoadableModules.cc
--- squid-3.2.0.14/src/LoadableModules.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/LoadableModules.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "squid.h"
+#include "squid-old.h"
 #include "wordlist.h"
 #include "LoadableModule.h"
 #include "LoadableModules.h"
diff -u -r -N squid-3.2.0.14/src/log/access_log.cc squid-3.2.0.15/src/log/access_log.cc
--- squid-3.2.0.14/src/log/access_log.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/log/access_log.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
  */
 
 
-#include "squid.h"
+#include "squid-old.h"
 #include "AccessLogEntry.h"
 
 // Store.h Required by configuration directives parsing/dumping only
diff -u -r -N squid-3.2.0.14/src/log/Config.cc squid-3.2.0.15/src/log/Config.cc
--- squid-3.2.0.14/src/log/Config.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/log/Config.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "config.h"
+#include "squid.h"
 #include "log/Config.h"
 #include "protos.h"
 
diff -u -r -N squid-3.2.0.14/src/log/File.cc squid-3.2.0.15/src/log/File.cc
--- squid-3.2.0.14/src/log/File.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/log/File.cc	2012-02-06 04:52:31.000000000 +1300
@@ -32,7 +32,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "fde.h"
 #include "log/File.h"
 #include "log/ModDaemon.h"
diff -u -r -N squid-3.2.0.14/src/log/FormatHttpdCombined.cc squid-3.2.0.15/src/log/FormatHttpdCombined.cc
--- squid-3.2.0.14/src/log/FormatHttpdCombined.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/log/FormatHttpdCombined.cc	2012-02-06 04:52:31.000000000 +1300
@@ -32,7 +32,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 #include "AccessLogEntry.h"
 #include "format/Token.h"
 #include "format/Quoting.h"
@@ -44,8 +44,6 @@
 void
 Log::Format::HttpdCombined(AccessLogEntry * al, Logfile * logfile)
 {
-    char clientip[MAX_IPSTRLEN];
-
     const char *user_ident = ::Format::QuoteUrlEncodeUsername(al->cache.rfc931);
 
     const char *user_auth = ::Format::QuoteUrlEncodeUsername(al->cache.authuser);
@@ -58,8 +56,11 @@
     if (!agent || *agent == '\0')
         agent = "-";
 
+    char clientip[MAX_IPSTRLEN];
+    al->getLogClientIp(clientip, MAX_IPSTRLEN);
+
     logfilePrintf(logfile, "%s %s %s [%s] \"%s %s %s/%d.%d\" %d %"PRId64" \"%s\" \"%s\" %s%s:%s%s",
-                  al->cache.caddr.NtoA(clientip,MAX_IPSTRLEN),
+                  clientip,
                   user_ident ? user_ident : dash_str,
                   user_auth ? user_auth : dash_str,
                   Time::FormatHttpd(squid_curtime),
diff -u -r -N squid-3.2.0.14/src/log/FormatHttpdCommon.cc squid-3.2.0.15/src/log/FormatHttpdCommon.cc
--- squid-3.2.0.14/src/log/FormatHttpdCommon.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/log/FormatHttpdCommon.cc	2012-02-06 04:52:31.000000000 +1300
@@ -32,7 +32,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 #include "AccessLogEntry.h"
 #include "format/Quoting.h"
 #include "format/Token.h"
@@ -43,12 +43,14 @@
 void
 Log::Format::HttpdCommon(AccessLogEntry * al, Logfile * logfile)
 {
-    char clientip[MAX_IPSTRLEN];
     const char *user_auth = ::Format::QuoteUrlEncodeUsername(al->cache.authuser);
     const char *user_ident = ::Format::QuoteUrlEncodeUsername(al->cache.rfc931);
 
+    char clientip[MAX_IPSTRLEN];
+    al->getLogClientIp(clientip, MAX_IPSTRLEN);
+
     logfilePrintf(logfile, "%s %s %s [%s] \"%s %s %s/%d.%d\" %d %"PRId64" %s%s:%s%s",
-                  al->cache.caddr.NtoA(clientip,MAX_IPSTRLEN),
+                  clientip,
                   user_ident ? user_ident : dash_str,
                   user_auth ? user_auth : dash_str,
                   Time::FormatHttpd(squid_curtime),
diff -u -r -N squid-3.2.0.14/src/log/FormatSquidCustom.cc squid-3.2.0.15/src/log/FormatSquidCustom.cc
--- squid-3.2.0.14/src/log/FormatSquidCustom.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/log/FormatSquidCustom.cc	2012-02-06 04:52:31.000000000 +1300
@@ -32,7 +32,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 #include "AccessLogEntry.h"
 #include "log/File.h"
 #include "log/Formats.h"
diff -u -r -N squid-3.2.0.14/src/log/FormatSquidIcap.cc squid-3.2.0.15/src/log/FormatSquidIcap.cc
--- squid-3.2.0.14/src/log/FormatSquidIcap.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/log/FormatSquidIcap.cc	2012-02-06 04:52:31.000000000 +1300
@@ -32,7 +32,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 
 #if ICAP_CLIENT
 
diff -u -r -N squid-3.2.0.14/src/log/FormatSquidNative.cc squid-3.2.0.15/src/log/FormatSquidNative.cc
--- squid-3.2.0.14/src/log/FormatSquidNative.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/log/FormatSquidNative.cc	2012-02-06 04:52:31.000000000 +1300
@@ -32,7 +32,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 #include "AccessLogEntry.h"
 #include "format/Quoting.h"
 #include "format/Token.h"
@@ -62,10 +62,7 @@
         safe_free(user);
 
     char clientip[MAX_IPSTRLEN];
-    if (al->tcpClient != NULL)
-        al->tcpClient->remote.NtoA(clientip, sizeof(clientip));
-    else
-        al->cache.caddr.NtoA(clientip, sizeof(clientip));
+    al->getLogClientIp(clientip, MAX_IPSTRLEN);
 
     logfilePrintf(logfile, "%9ld.%03d %6d %s %s%s/%03d %"PRId64" %s %s %s %s%s/%s %s%s",
                   (long int) current_time.tv_sec,
diff -u -r -N squid-3.2.0.14/src/log/FormatSquidReferer.cc squid-3.2.0.15/src/log/FormatSquidReferer.cc
--- squid-3.2.0.14/src/log/FormatSquidReferer.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/log/FormatSquidReferer.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 #include "AccessLogEntry.h"
 #include "HttpRequest.h"
 #include "log/File.h"
@@ -50,11 +50,12 @@
         return;
 
     char clientip[MAX_IPSTRLEN];
+    al->getLogClientIp(clientip, MAX_IPSTRLEN);
 
     logfilePrintf(logfile, "%9ld.%03d %s %s %s\n",
                   (long int) current_time.tv_sec,
                   (int) current_time.tv_usec / 1000,
-                  al->cache.caddr.NtoA(clientip, MAX_IPSTRLEN),
+                  clientip,
                   referer,
                   al->url ? al->url : "-");
 }
diff -u -r -N squid-3.2.0.14/src/log/FormatSquidUseragent.cc squid-3.2.0.15/src/log/FormatSquidUseragent.cc
--- squid-3.2.0.14/src/log/FormatSquidUseragent.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/log/FormatSquidUseragent.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 #include "AccessLogEntry.h"
 #include "HttpRequest.h"
 #include "log/File.h"
@@ -43,16 +43,17 @@
 void
 Log::Format::SquidUserAgent(AccessLogEntry * al, Logfile * logfile)
 {
-    char clientip[MAX_IPSTRLEN];
-
     const char *agent = al->request->header.getStr(HDR_USER_AGENT);
 
     // do not log unless there is something to be displayed.
     if (!agent || *agent == '\0')
         return;
 
+    char clientip[MAX_IPSTRLEN];
+    al->getLogClientIp(clientip, MAX_IPSTRLEN);
+
     logfilePrintf(logfile, "%s [%s] \"%s\"\n",
-                  al->cache.caddr.NtoA(clientip,MAX_IPSTRLEN),
+                  clientip,
                   Time::FormatHttpd(squid_curtime),
                   agent);
 }
diff -u -r -N squid-3.2.0.14/src/log/ModDaemon.cc squid-3.2.0.15/src/log/ModDaemon.cc
--- squid-3.2.0.14/src/log/ModDaemon.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/log/ModDaemon.cc	2012-02-06 04:52:31.000000000 +1300
@@ -30,7 +30,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "cbdata.h"
 #include "comm/Loops.h"
 #include "fde.h"
diff -u -r -N squid-3.2.0.14/src/log/ModStdio.cc squid-3.2.0.15/src/log/ModStdio.cc
--- squid-3.2.0.14/src/log/ModStdio.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/log/ModStdio.cc	2012-02-06 04:52:31.000000000 +1300
@@ -30,7 +30,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "fde.h"
 #include "log/File.h"
 #include "log/ModStdio.h"
diff -u -r -N squid-3.2.0.14/src/log/ModSyslog.cc squid-3.2.0.15/src/log/ModSyslog.cc
--- squid-3.2.0.14/src/log/ModSyslog.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/log/ModSyslog.cc	2012-02-06 04:52:31.000000000 +1300
@@ -30,7 +30,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 
 #if HAVE_SYSLOG
 
diff -u -r -N squid-3.2.0.14/src/log/ModTcp.cc squid-3.2.0.15/src/log/ModTcp.cc
--- squid-3.2.0.14/src/log/ModTcp.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/log/ModTcp.cc	2012-02-06 04:52:31.000000000 +1300
@@ -31,7 +31,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "comm.h"
 #include "comm/Connection.h"
 #include "log/File.h"
diff -u -r -N squid-3.2.0.14/src/log/ModUdp.cc squid-3.2.0.15/src/log/ModUdp.cc
--- squid-3.2.0.14/src/log/ModUdp.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/log/ModUdp.cc	2012-02-06 04:52:31.000000000 +1300
@@ -30,7 +30,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "comm.h"
 #include "comm/Connection.h"
 #include "log/File.h"
diff -u -r -N squid-3.2.0.14/src/main.cc squid-3.2.0.15/src/main.cc
--- squid-3.2.0.14/src/main.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/main.cc	2012-02-06 04:52:31.000000000 +1300
@@ -32,7 +32,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "AccessLogEntry.h"
 #if USE_ADAPTATION
 #include "adaptation/Config.h"
@@ -66,6 +66,7 @@
 #include "format/Token.h"
 #include "fs/Module.h"
 #include "PeerSelectState.h"
+#include "SquidDns.h"
 #include "Store.h"
 #include "ICP.h"
 #include "ident/Ident.h"
@@ -734,13 +735,7 @@
 
     htcpSocketClose();
 #endif
-#if USE_DNSSERVERS
-
     dnsShutdown();
-#else
-
-    idnsShutdown();
-#endif
 #if USE_SSL_CRTD
     Ssl::Helper::GetInstance()->Shutdown();
 #endif
@@ -823,13 +818,7 @@
     icapLogOpen();
 #endif
     storeLogOpen();
-#if USE_DNSSERVERS
-
     dnsInit();
-#else
-
-    idnsInit();
-#endif
 #if USE_SSL_CRTD
     Ssl::Helper::GetInstance()->Init();
 #endif
@@ -878,8 +867,6 @@
 
     writePidFile();		/* write PID file */
 
-    debugs(1, 1, "Ready to serve requests.");
-
     reconfiguring = 0;
 }
 
@@ -887,7 +874,7 @@
 mainRotate(void)
 {
     icmpEngine.Close();
-#if USE_DNSSERVERS
+#if USE_DNSHELPER
     dnsShutdown();
 #endif
     redirectShutdown();
@@ -904,7 +891,7 @@
     icapLogRotate();               /*icap.log*/
 #endif
     icmpEngine.Open();
-#if USE_DNSSERVERS
+#if USE_DNSHELPER
     dnsInit();
 #endif
     redirectInit();
@@ -1028,16 +1015,8 @@
 
     parseEtcHosts();
 
-#if USE_DNSSERVERS
-
     dnsInit();
 
-#else
-
-    idnsInit();
-
-#endif
-
 #if USE_SSL_CRTD
     Ssl::Helper::GetInstance()->Init();
 #endif
@@ -1189,8 +1168,6 @@
     Config.ClientDelay.finalize();
 #endif
 
-    debugs(1, 1, "Ready to serve requests.");
-
     if (!configured_once) {
         eventAdd("storeMaintain", Store::Maintain, NULL, 1.0, 1);
 
@@ -1437,6 +1414,7 @@
 
     debugs(1,2, HERE << "Doing post-config initialization\n");
     leave_suid();
+    ActivateRegistered(rrFinalizeConfig);
     ActivateRegistered(rrClaimMemoryNeeds);
     ActivateRegistered(rrAfterConfig);
     enter_suid();
@@ -1808,6 +1786,7 @@
             leave_suid();
             DeactivateRegistered(rrAfterConfig);
             DeactivateRegistered(rrClaimMemoryNeeds);
+            DeactivateRegistered(rrFinalizeConfig);
             enter_suid();
 
             if (TheKids.someSignaled(SIGINT) || TheKids.someSignaled(SIGTERM)) {
@@ -1846,13 +1825,7 @@
 #endif
 
     debugs(1, 1, "Shutting down...");
-#if USE_DNSSERVERS
-
     dnsShutdown();
-#else
-
-    idnsShutdown();
-#endif
 #if USE_SSL_CRTD
     Ssl::Helper::GetInstance()->Shutdown();
 #endif
@@ -1910,6 +1883,7 @@
     DiskIOModule::FreeAllModules();
     DeactivateRegistered(rrAfterConfig);
     DeactivateRegistered(rrClaimMemoryNeeds);
+    DeactivateRegistered(rrFinalizeConfig);
 #if LEAK_CHECK_MODE && 0 /* doesn't work at the moment */
 
     configFreeMemory();
diff -u -r -N squid-3.2.0.14/src/Makefile.am squid-3.2.0.15/src/Makefile.am
--- squid-3.2.0.14/src/Makefile.am	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/Makefile.am	2012-02-06 04:52:31.000000000 +1300
@@ -7,15 +7,17 @@
 include $(top_srcdir)/src/Common.am
 
 AUTOMAKE_OPTIONS = subdir-objects
-if USE_DNSSERVER
+
+if ENABLE_DNSHELPER
 DNSSOURCE = dns.cc
-DNSSERVER = dnsserver
+DNSHELPER = dnsserver
 else
 DNSSOURCE = dns_internal.cc
-DNSSERVER =
+DNSHELPER =
 endif
 
 DNSSOURCE += \
+	SquidDns.h \
 	DnsLookupDetails.h \
 	DnsLookupDetails.cc
 
@@ -203,7 +205,7 @@
 
 
 libexec_PROGRAMS = \
-	$(DNSSERVER) \
+	$(DNSHELPER) \
 	$(DISK_PROGRAMS) \
 	$(UNLINKD)
 
@@ -253,6 +255,7 @@
 
 squid_SOURCES = \
 	$(ACL_REGISTRATION_SOURCES) \
+	AccessLogEntry.cc \
 	AccessLogEntry.h \
 	AsyncEngine.cc \
 	AsyncEngine.h \
@@ -420,7 +423,7 @@
 	send-announce.cc \
 	$(SBUF_SOURCE) \
 	$(SNMP_SOURCE) \
-	squid.h \
+	squid-old.h \
 	SquidMath.h \
 	SquidMath.cc \
 	SquidNew.cc \
@@ -626,14 +629,11 @@
 
 unlinkd_SOURCES = unlinkd_daemon.cc
 unlinkd_LDADD = \
-	ipc/libipc.la \
-	ip/libip.la \
 	$(COMPAT_LIB) \
 	$(XTRA_LIBS)
 
 ## dnsserver is a standalone helper. Do not link to any internal libraries
 dnsserver_SOURCES = dnsserver.cc
-## SquidNew.cc tests/stub_debug.cc test_tools.cc time.cc
 dnsserver_LDADD = $(COMPAT_LIB)
 
 recv_announce_SOURCES = recv-announce.cc
@@ -687,7 +687,7 @@
 	tests/stub_HelperChildConfig.cc \
 	HttpRequestMethod.cc \
 	RemovalPolicy.cc \
-	squid.h \
+	squid-old.h \
 	$(WIN32_SOURCE) \
 	tests/stub_fd.cc
 ufsdump_LDADD = \
@@ -1251,6 +1251,7 @@
 
 ## Tests of the CacheManager module.
 tests_testCacheManager_SOURCES = \
+	AccessLogEntry.cc \
 	$(ACL_REGISTRATION_SOURCES) \
 	debug.cc \
 	HttpParser.cc \
@@ -1583,6 +1584,7 @@
 
 ## Tests of the Even module.
 tests_testEvent_SOURCES = \
+	AccessLogEntry.cc \
 	$(ACL_REGISTRATION_SOURCES) \
 	BodyPipe.cc \
 	CacheDigest.cc \
@@ -1773,6 +1775,7 @@
 
 ## Tests of the EventLoop module.
 tests_testEventLoop_SOURCES = \
+	AccessLogEntry.cc \
 	$(ACL_REGISTRATION_SOURCES) \
 	BodyPipe.cc \
 	CacheDigest.cc \
@@ -1961,6 +1964,7 @@
 	$(SQUID_CPPUNIT_LA)
 
 tests_test_http_range_SOURCES = \
+	AccessLogEntry.cc \
 	$(ACL_REGISTRATION_SOURCES) \
 	BodyPipe.cc \
 	cache_cf.cc \
@@ -2179,6 +2183,7 @@
 
 ## Tests of the HttpRequest module.
 tests_testHttpRequest_SOURCES = \
+	AccessLogEntry.cc \
 	$(ACL_REGISTRATION_SOURCES) \
 	HttpParser.cc \
 	HttpParser.h \
@@ -3079,6 +3084,7 @@
 ## Tests of the URL module.
 ## TODO: Trim this down once the insanity is over.
 tests_testURL_SOURCES = \
+	AccessLogEntry.cc \
 	$(ACL_REGISTRATION_SOURCES) \
 	BodyPipe.cc \
 	cache_cf.cc \
diff -u -r -N squid-3.2.0.14/src/Makefile.in squid-3.2.0.15/src/Makefile.in
--- squid-3.2.0.14/src/Makefile.in	2011-12-13 00:10:40.000000000 +1300
+++ squid-3.2.0.15/src/Makefile.in	2012-02-06 04:58:32.000000000 +1300
@@ -162,7 +162,7 @@
 	"$(DESTDIR)$(sbindir)" "$(DESTDIR)$(man8dir)" \
 	"$(DESTDIR)$(datadir)" "$(DESTDIR)$(sysconfdir)"
 @ENABLE_AUTH_TRUE@am__EXEEXT_1 = tests/testACLMaxUserIP$(EXEEXT)
-@USE_DNSSERVER_TRUE@am__EXEEXT_2 = dnsserver$(EXEEXT)
+@ENABLE_DNSHELPER_TRUE@am__EXEEXT_2 = dnsserver$(EXEEXT)
 @ENABLE_UNLINKD_TRUE@am__EXEEXT_3 = unlinkd$(EXEEXT)
 PROGRAMS = $(bin_PROGRAMS) $(libexec_PROGRAMS) $(noinst_PROGRAMS) \
 	$(sbin_PROGRAMS)
@@ -195,33 +195,34 @@
 	fs/libfs.la ipc/libipc.la mgr/libmgr.la $(am__DEPENDENCIES_3) \
 	$(am__DEPENDENCIES_3) $(am__DEPENDENCIES_2) \
 	$(am__DEPENDENCIES_3)
-am__squid_SOURCES_DIST = AclRegs.cc AuthReg.cc AccessLogEntry.h \
-	AsyncEngine.cc AsyncEngine.h cache_cf.cc ProtoPort.cc \
-	ProtoPort.h CacheDigest.cc cache_manager.cc CacheManager.h \
-	carp.cc cbdata.cc cbdata.h ChunkedCodingParser.cc \
-	ChunkedCodingParser.h client_db.cc client_side.cc \
-	client_side.h client_side_reply.cc client_side_reply.h \
-	client_side_request.cc client_side_request.h ClientInfo.h \
-	BodyPipe.cc BodyPipe.h ClientRequestContext.h clientStream.cc \
-	clientStream.h CommIO.h CompletionDispatcher.cc \
-	CompletionDispatcher.h CommRead.h ConfigOption.cc \
-	ConfigParser.cc ConfigParser.h CpuAffinity.cc CpuAffinity.h \
-	CpuAffinityMap.cc CpuAffinityMap.h CpuAffinitySet.cc \
-	CpuAffinitySet.h debug.cc Debug.h defines.h CommonPool.h \
-	CompositePoolNode.h delay_pools.cc DelayId.cc DelayId.h \
-	DelayIdComposite.h DelayBucket.cc DelayBucket.h DelayConfig.cc \
-	DelayConfig.h DelayPool.cc DelayPool.h DelayPools.h \
-	DelaySpec.cc DelaySpec.h DelayTagged.cc DelayTagged.h \
-	DelayUser.cc DelayUser.h DelayVector.cc DelayVector.h \
-	NullDelayId.cc NullDelayId.h ClientDelayConfig.cc \
-	ClientDelayConfig.h disk.cc DiskIO/DiskIOModule.cc \
-	DiskIO/ReadRequest.cc DiskIO/ReadRequest.h \
-	DiskIO/WriteRequest.cc DiskIO/WriteRequest.h DiskIO/DiskFile.h \
+am__squid_SOURCES_DIST = AclRegs.cc AuthReg.cc AccessLogEntry.cc \
+	AccessLogEntry.h AsyncEngine.cc AsyncEngine.h cache_cf.cc \
+	ProtoPort.cc ProtoPort.h CacheDigest.cc cache_manager.cc \
+	CacheManager.h carp.cc cbdata.cc cbdata.h \
+	ChunkedCodingParser.cc ChunkedCodingParser.h client_db.cc \
+	client_side.cc client_side.h client_side_reply.cc \
+	client_side_reply.h client_side_request.cc \
+	client_side_request.h ClientInfo.h BodyPipe.cc BodyPipe.h \
+	ClientRequestContext.h clientStream.cc clientStream.h CommIO.h \
+	CompletionDispatcher.cc CompletionDispatcher.h CommRead.h \
+	ConfigOption.cc ConfigParser.cc ConfigParser.h CpuAffinity.cc \
+	CpuAffinity.h CpuAffinityMap.cc CpuAffinityMap.h \
+	CpuAffinitySet.cc CpuAffinitySet.h debug.cc Debug.h defines.h \
+	CommonPool.h CompositePoolNode.h delay_pools.cc DelayId.cc \
+	DelayId.h DelayIdComposite.h DelayBucket.cc DelayBucket.h \
+	DelayConfig.cc DelayConfig.h DelayPool.cc DelayPool.h \
+	DelayPools.h DelaySpec.cc DelaySpec.h DelayTagged.cc \
+	DelayTagged.h DelayUser.cc DelayUser.h DelayVector.cc \
+	DelayVector.h NullDelayId.cc NullDelayId.h \
+	ClientDelayConfig.cc ClientDelayConfig.h disk.cc \
+	DiskIO/DiskIOModule.cc DiskIO/ReadRequest.cc \
+	DiskIO/ReadRequest.h DiskIO/WriteRequest.cc \
+	DiskIO/WriteRequest.h DiskIO/DiskFile.h \
 	DiskIO/DiskIOStrategy.h DiskIO/IORequestor.h \
 	DiskIO/DiskIOModule.h dlink.h dlink.cc dns_internal.cc \
-	DnsLookupDetails.h DnsLookupDetails.cc dns.cc enums.h \
-	err_type.h err_detail_type.h errorpage.cc errorpage.h ETag.cc \
-	ETag.h event.cc event.h EventLoop.h EventLoop.cc \
+	SquidDns.h DnsLookupDetails.h DnsLookupDetails.cc dns.cc \
+	enums.h err_type.h err_detail_type.h errorpage.cc errorpage.h \
+	ETag.cc ETag.h event.cc event.h EventLoop.h EventLoop.cc \
 	external_acl.cc ExternalACL.h ExternalACLEntry.cc \
 	ExternalACLEntry.h FadingCounter.h FadingCounter.cc fd.cc \
 	fde.cc fde.h FileMap.h filemap.cc forward.cc forward.h \
@@ -247,7 +248,7 @@
 	peer_userhash.cc PeerSelectState.h PingData.h protos.h \
 	redirect.cc refresh.cc RemovalPolicy.cc RemovalPolicy.h \
 	send-announce.cc base/InstanceId.h MemBlob.h MemBlob.cc \
-	snmp_core.h snmp_core.cc snmp_agent.cc squid.h SquidMath.h \
+	snmp_core.h snmp_core.cc snmp_agent.cc squid-old.h SquidMath.h \
 	SquidMath.cc SquidNew.cc stat.cc StatHist.cc String.cc \
 	stmem.cc stmem.h store.cc Store.h StoreFileSystem.cc \
 	StoreFileSystem.h StoreHashIndex.h store_io.cc StoreIOBuffer.h \
@@ -276,10 +277,10 @@
 @ENABLE_DELAY_POOLS_TRUE@am__objects_6 = $(am__objects_5)
 am__objects_7 = DiskIO/DiskIOModule.$(OBJEXT) \
 	DiskIO/ReadRequest.$(OBJEXT) DiskIO/WriteRequest.$(OBJEXT)
-@USE_DNSSERVER_FALSE@am__objects_8 = dns_internal.$(OBJEXT) \
-@USE_DNSSERVER_FALSE@	DnsLookupDetails.$(OBJEXT)
-@USE_DNSSERVER_TRUE@am__objects_8 = dns.$(OBJEXT) \
-@USE_DNSSERVER_TRUE@	DnsLookupDetails.$(OBJEXT)
+@ENABLE_DNSHELPER_FALSE@am__objects_8 = dns_internal.$(OBJEXT) \
+@ENABLE_DNSHELPER_FALSE@	DnsLookupDetails.$(OBJEXT)
+@ENABLE_DNSHELPER_TRUE@am__objects_8 = dns.$(OBJEXT) \
+@ENABLE_DNSHELPER_TRUE@	DnsLookupDetails.$(OBJEXT)
 @ENABLE_HTCP_TRUE@am__objects_9 = htcp.$(OBJEXT)
 @USE_IPC_WIN32_FALSE@am__objects_10 = ipc.$(OBJEXT)
 @USE_IPC_WIN32_TRUE@am__objects_10 = ipc_win32.$(OBJEXT)
@@ -293,19 +294,20 @@
 @ENABLE_WIN32SPECIFIC_TRUE@am__objects_18 = WinSvc.$(OBJEXT)
 am__objects_19 = LoadableModule.$(OBJEXT) LoadableModules.$(OBJEXT)
 @USE_LOADABLE_MODULES_TRUE@am__objects_20 = $(am__objects_19)
-am_squid_OBJECTS = $(am__objects_4) AsyncEngine.$(OBJEXT) \
-	cache_cf.$(OBJEXT) ProtoPort.$(OBJEXT) CacheDigest.$(OBJEXT) \
-	cache_manager.$(OBJEXT) carp.$(OBJEXT) cbdata.$(OBJEXT) \
-	ChunkedCodingParser.$(OBJEXT) client_db.$(OBJEXT) \
-	client_side.$(OBJEXT) client_side_reply.$(OBJEXT) \
-	client_side_request.$(OBJEXT) BodyPipe.$(OBJEXT) \
-	clientStream.$(OBJEXT) CompletionDispatcher.$(OBJEXT) \
-	ConfigOption.$(OBJEXT) ConfigParser.$(OBJEXT) \
-	CpuAffinity.$(OBJEXT) CpuAffinityMap.$(OBJEXT) \
-	CpuAffinitySet.$(OBJEXT) debug.$(OBJEXT) $(am__objects_6) \
-	disk.$(OBJEXT) $(am__objects_7) dlink.$(OBJEXT) \
-	$(am__objects_8) errorpage.$(OBJEXT) ETag.$(OBJEXT) \
-	event.$(OBJEXT) EventLoop.$(OBJEXT) external_acl.$(OBJEXT) \
+am_squid_OBJECTS = $(am__objects_4) AccessLogEntry.$(OBJEXT) \
+	AsyncEngine.$(OBJEXT) cache_cf.$(OBJEXT) ProtoPort.$(OBJEXT) \
+	CacheDigest.$(OBJEXT) cache_manager.$(OBJEXT) carp.$(OBJEXT) \
+	cbdata.$(OBJEXT) ChunkedCodingParser.$(OBJEXT) \
+	client_db.$(OBJEXT) client_side.$(OBJEXT) \
+	client_side_reply.$(OBJEXT) client_side_request.$(OBJEXT) \
+	BodyPipe.$(OBJEXT) clientStream.$(OBJEXT) \
+	CompletionDispatcher.$(OBJEXT) ConfigOption.$(OBJEXT) \
+	ConfigParser.$(OBJEXT) CpuAffinity.$(OBJEXT) \
+	CpuAffinityMap.$(OBJEXT) CpuAffinitySet.$(OBJEXT) \
+	debug.$(OBJEXT) $(am__objects_6) disk.$(OBJEXT) \
+	$(am__objects_7) dlink.$(OBJEXT) $(am__objects_8) \
+	errorpage.$(OBJEXT) ETag.$(OBJEXT) event.$(OBJEXT) \
+	EventLoop.$(OBJEXT) external_acl.$(OBJEXT) \
 	ExternalACLEntry.$(OBJEXT) FadingCounter.$(OBJEXT) \
 	fd.$(OBJEXT) fde.$(OBJEXT) filemap.$(OBJEXT) forward.$(OBJEXT) \
 	fqdncache.$(OBJEXT) ftp.$(OBJEXT) gopher.$(OBJEXT) \
@@ -422,8 +424,8 @@
 tests_testBoilerplate_LINK = $(LIBTOOL) --tag=CXX $(AM_LIBTOOLFLAGS) \
 	$(LIBTOOLFLAGS) --mode=link $(CXXLD) $(AM_CXXFLAGS) \
 	$(CXXFLAGS) $(tests_testBoilerplate_LDFLAGS) $(LDFLAGS) -o $@
-am__tests_testCacheManager_SOURCES_DIST = AclRegs.cc AuthReg.cc \
-	debug.cc HttpParser.cc HttpParser.h HttpRequest.cc \
+am__tests_testCacheManager_SOURCES_DIST = AccessLogEntry.cc AclRegs.cc \
+	AuthReg.cc debug.cc HttpParser.cc HttpParser.h HttpRequest.cc \
 	HttpRequestMethod.cc mem.cc String.cc \
 	tests/testCacheManager.cc tests/testCacheManager.h \
 	tests/testMain.cc tests/stub_main_cc.cc \
@@ -446,18 +448,19 @@
 	DiskIO/WriteRequest.h DiskIO/DiskFile.h \
 	DiskIO/DiskIOStrategy.h DiskIO/IORequestor.h \
 	DiskIO/DiskIOModule.h disk.cc dlink.h dlink.cc dns_internal.cc \
-	DnsLookupDetails.h DnsLookupDetails.cc dns.cc errorpage.cc \
-	ETag.cc event.cc external_acl.cc ExternalACLEntry.cc fd.cc \
-	fde.cc FileMap.h filemap.cc forward.cc fqdncache.cc ftp.cc \
-	gopher.cc hier_code.h helper.cc HelperChildConfig.h \
-	HelperChildConfig.cc htcp.cc htcp.h http.cc HttpBody.h \
-	HttpBody.cc HttpHeader.cc HttpHeaderTools.cc HttpHdrCc.h \
-	HttpHdrCc.cc HttpHdrCc.cci HttpHdrContRange.cc HttpHdrRange.cc \
-	HttpHdrSc.cc HttpHdrScTarget.cc HttpMsg.cc HttpReply.cc \
-	HttpStatusLine.cc icp_v2.cc icp_v3.cc ipc.cc ipc_win32.cc \
-	ipcache.cc int.cc internal.cc list.cc multicast.cc mem_node.cc \
-	MemBuf.cc MemObject.cc mime.cc mime_header.cc neighbors.cc \
-	Packer.cc Parsing.cc pconn.cc peer_digest.cc \
+	SquidDns.h DnsLookupDetails.h DnsLookupDetails.cc dns.cc \
+	errorpage.cc ETag.cc event.cc external_acl.cc \
+	ExternalACLEntry.cc fd.cc fde.cc FileMap.h filemap.cc \
+	forward.cc fqdncache.cc ftp.cc gopher.cc hier_code.h helper.cc \
+	HelperChildConfig.h HelperChildConfig.cc htcp.cc htcp.h \
+	http.cc HttpBody.h HttpBody.cc HttpHeader.cc \
+	HttpHeaderTools.cc HttpHdrCc.h HttpHdrCc.cc HttpHdrCc.cci \
+	HttpHdrContRange.cc HttpHdrRange.cc HttpHdrSc.cc \
+	HttpHdrScTarget.cc HttpMsg.cc HttpReply.cc HttpStatusLine.cc \
+	icp_v2.cc icp_v3.cc ipc.cc ipc_win32.cc ipcache.cc int.cc \
+	internal.cc list.cc multicast.cc mem_node.cc MemBuf.cc \
+	MemObject.cc mime.cc mime_header.cc neighbors.cc Packer.cc \
+	Parsing.cc pconn.cc peer_digest.cc \
 	peer_proxy_negotiate_auth.cc peer_select.cc peer_sourcehash.cc \
 	peer_userhash.cc redirect.cc refresh.cc RemovalPolicy.cc \
 	Server.cc snmp_core.h snmp_core.cc snmp_agent.cc SquidMath.h \
@@ -470,9 +473,10 @@
 	StoreMetaVary.cc StoreSwapLogData.cc tools.cc tunnel.cc \
 	SwapDir.cc MemStore.cc unlinkd.cc url.cc URLScheme.cc urn.cc \
 	wccp2.cc whois.cc FadingCounter.cc win32.cc wordlist.cc
-am_tests_testCacheManager_OBJECTS = $(am__objects_4) debug.$(OBJEXT) \
-	HttpParser.$(OBJEXT) HttpRequest.$(OBJEXT) \
-	HttpRequestMethod.$(OBJEXT) mem.$(OBJEXT) String.$(OBJEXT) \
+am_tests_testCacheManager_OBJECTS = AccessLogEntry.$(OBJEXT) \
+	$(am__objects_4) debug.$(OBJEXT) HttpParser.$(OBJEXT) \
+	HttpRequest.$(OBJEXT) HttpRequestMethod.$(OBJEXT) \
+	mem.$(OBJEXT) String.$(OBJEXT) \
 	tests/testCacheManager.$(OBJEXT) tests/testMain.$(OBJEXT) \
 	tests/stub_main_cc.$(OBJEXT) \
 	tests/stub_ipc_Forwarder.$(OBJEXT) \
@@ -717,32 +721,33 @@
 tests_testDiskIO_LINK = $(LIBTOOL) --tag=CXX $(AM_LIBTOOLFLAGS) \
 	$(LIBTOOLFLAGS) --mode=link $(CXXLD) $(AM_CXXFLAGS) \
 	$(CXXFLAGS) $(tests_testDiskIO_LDFLAGS) $(LDFLAGS) -o $@
-am__tests_testEvent_SOURCES_DIST = AclRegs.cc AuthReg.cc BodyPipe.cc \
-	CacheDigest.cc cache_cf.cc cache_manager.cc carp.cc cbdata.cc \
-	ChunkedCodingParser.cc client_db.cc client_side.cc \
-	client_side_reply.cc client_side_request.cc ClientInfo.h \
-	clientStream.cc ConfigOption.cc ConfigParser.cc \
-	CpuAffinityMap.cc CpuAffinityMap.h CpuAffinitySet.cc \
-	CpuAffinitySet.h debug.cc CommonPool.h CompositePoolNode.h \
-	delay_pools.cc DelayId.cc DelayId.h DelayIdComposite.h \
-	DelayBucket.cc DelayBucket.h DelayConfig.cc DelayConfig.h \
-	DelayPool.cc DelayPool.h DelayPools.h DelaySpec.cc DelaySpec.h \
-	DelayTagged.cc DelayTagged.h DelayUser.cc DelayUser.h \
-	DelayVector.cc DelayVector.h NullDelayId.cc NullDelayId.h \
+am__tests_testEvent_SOURCES_DIST = AccessLogEntry.cc AclRegs.cc \
+	AuthReg.cc BodyPipe.cc CacheDigest.cc cache_cf.cc \
+	cache_manager.cc carp.cc cbdata.cc ChunkedCodingParser.cc \
+	client_db.cc client_side.cc client_side_reply.cc \
+	client_side_request.cc ClientInfo.h clientStream.cc \
+	ConfigOption.cc ConfigParser.cc CpuAffinityMap.cc \
+	CpuAffinityMap.h CpuAffinitySet.cc CpuAffinitySet.h debug.cc \
+	CommonPool.h CompositePoolNode.h delay_pools.cc DelayId.cc \
+	DelayId.h DelayIdComposite.h DelayBucket.cc DelayBucket.h \
+	DelayConfig.cc DelayConfig.h DelayPool.cc DelayPool.h \
+	DelayPools.h DelaySpec.cc DelaySpec.h DelayTagged.cc \
+	DelayTagged.h DelayUser.cc DelayUser.h DelayVector.cc \
+	DelayVector.h NullDelayId.cc NullDelayId.h \
 	ClientDelayConfig.cc ClientDelayConfig.h \
 	DiskIO/DiskIOModule.cc DiskIO/ReadRequest.cc \
 	DiskIO/ReadRequest.h DiskIO/WriteRequest.cc \
 	DiskIO/WriteRequest.h DiskIO/DiskFile.h \
 	DiskIO/DiskIOStrategy.h DiskIO/IORequestor.h \
 	DiskIO/DiskIOModule.h disk.cc dlink.h dlink.cc dns_internal.cc \
-	DnsLookupDetails.h DnsLookupDetails.cc dns.cc errorpage.cc \
-	ETag.cc event.cc EventLoop.h EventLoop.cc external_acl.cc \
-	ExternalACLEntry.cc FadingCounter.cc fd.cc fde.cc FileMap.h \
-	filemap.cc forward.cc fqdncache.cc ftp.cc gopher.cc helper.cc \
-	HelperChildConfig.h HelperChildConfig.cc hier_code.h htcp.cc \
-	htcp.h http.cc HttpBody.h HttpBody.cc HttpHeader.cc \
-	HttpHeaderTools.cc HttpHdrCc.h HttpHdrCc.cc HttpHdrCc.cci \
-	HttpHdrContRange.cc HttpHdrRange.cc HttpHdrSc.cc \
+	SquidDns.h DnsLookupDetails.h DnsLookupDetails.cc dns.cc \
+	errorpage.cc ETag.cc event.cc EventLoop.h EventLoop.cc \
+	external_acl.cc ExternalACLEntry.cc FadingCounter.cc fd.cc \
+	fde.cc FileMap.h filemap.cc forward.cc fqdncache.cc ftp.cc \
+	gopher.cc helper.cc HelperChildConfig.h HelperChildConfig.cc \
+	hier_code.h htcp.cc htcp.h http.cc HttpBody.h HttpBody.cc \
+	HttpHeader.cc HttpHeaderTools.cc HttpHdrCc.h HttpHdrCc.cc \
+	HttpHdrCc.cci HttpHdrContRange.cc HttpHdrRange.cc HttpHdrSc.cc \
 	HttpHdrScTarget.cc HttpMsg.cc HttpParser.cc HttpParser.h \
 	HttpReply.cc HttpRequest.cc HttpRequestMethod.cc \
 	HttpStatusLine.cc icp_v2.cc icp_v3.cc ipc.cc ipc_win32.cc \
@@ -765,8 +770,8 @@
 	tests/stub_ipc_Forwarder.cc tests/stub_store_stats.cc time.cc \
 	tools.cc tunnel.cc MemStore.cc unlinkd.cc url.cc URLScheme.cc \
 	urn.cc wccp2.cc whois.cc win32.cc wordlist.cc
-am_tests_testEvent_OBJECTS = $(am__objects_4) BodyPipe.$(OBJEXT) \
-	CacheDigest.$(OBJEXT) cache_cf.$(OBJEXT) \
+am_tests_testEvent_OBJECTS = AccessLogEntry.$(OBJEXT) $(am__objects_4) \
+	BodyPipe.$(OBJEXT) CacheDigest.$(OBJEXT) cache_cf.$(OBJEXT) \
 	cache_manager.$(OBJEXT) carp.$(OBJEXT) cbdata.$(OBJEXT) \
 	ChunkedCodingParser.$(OBJEXT) client_db.$(OBJEXT) \
 	client_side.$(OBJEXT) client_side_reply.$(OBJEXT) \
@@ -823,32 +828,33 @@
 tests_testEvent_LINK = $(LIBTOOL) --tag=CXX $(AM_LIBTOOLFLAGS) \
 	$(LIBTOOLFLAGS) --mode=link $(CXXLD) $(AM_CXXFLAGS) \
 	$(CXXFLAGS) $(tests_testEvent_LDFLAGS) $(LDFLAGS) -o $@
-am__tests_testEventLoop_SOURCES_DIST = AclRegs.cc AuthReg.cc \
-	BodyPipe.cc CacheDigest.cc cache_manager.cc cache_cf.cc \
-	carp.cc cbdata.cc ChunkedCodingParser.cc client_db.cc \
-	client_side.cc client_side_reply.cc client_side_request.cc \
-	ClientInfo.h clientStream.cc ConfigOption.cc ConfigParser.cc \
-	CpuAffinityMap.cc CpuAffinityMap.h CpuAffinitySet.cc \
-	CpuAffinitySet.h debug.cc CommonPool.h CompositePoolNode.h \
-	delay_pools.cc DelayId.cc DelayId.h DelayIdComposite.h \
-	DelayBucket.cc DelayBucket.h DelayConfig.cc DelayConfig.h \
-	DelayPool.cc DelayPool.h DelayPools.h DelaySpec.cc DelaySpec.h \
-	DelayTagged.cc DelayTagged.h DelayUser.cc DelayUser.h \
-	DelayVector.cc DelayVector.h NullDelayId.cc NullDelayId.h \
+am__tests_testEventLoop_SOURCES_DIST = AccessLogEntry.cc AclRegs.cc \
+	AuthReg.cc BodyPipe.cc CacheDigest.cc cache_manager.cc \
+	cache_cf.cc carp.cc cbdata.cc ChunkedCodingParser.cc \
+	client_db.cc client_side.cc client_side_reply.cc \
+	client_side_request.cc ClientInfo.h clientStream.cc \
+	ConfigOption.cc ConfigParser.cc CpuAffinityMap.cc \
+	CpuAffinityMap.h CpuAffinitySet.cc CpuAffinitySet.h debug.cc \
+	CommonPool.h CompositePoolNode.h delay_pools.cc DelayId.cc \
+	DelayId.h DelayIdComposite.h DelayBucket.cc DelayBucket.h \
+	DelayConfig.cc DelayConfig.h DelayPool.cc DelayPool.h \
+	DelayPools.h DelaySpec.cc DelaySpec.h DelayTagged.cc \
+	DelayTagged.h DelayUser.cc DelayUser.h DelayVector.cc \
+	DelayVector.h NullDelayId.cc NullDelayId.h \
 	ClientDelayConfig.cc ClientDelayConfig.h \
 	DiskIO/DiskIOModule.cc DiskIO/ReadRequest.cc \
 	DiskIO/ReadRequest.h DiskIO/WriteRequest.cc \
 	DiskIO/WriteRequest.h DiskIO/DiskFile.h \
 	DiskIO/DiskIOStrategy.h DiskIO/IORequestor.h \
 	DiskIO/DiskIOModule.h disk.cc dlink.h dlink.cc dns_internal.cc \
-	DnsLookupDetails.h DnsLookupDetails.cc dns.cc errorpage.cc \
-	ETag.cc EventLoop.h EventLoop.cc event.cc external_acl.cc \
-	ExternalACLEntry.cc FadingCounter.cc fd.cc fde.cc FileMap.h \
-	filemap.cc forward.cc fqdncache.cc ftp.cc gopher.cc helper.cc \
-	HelperChildConfig.h HelperChildConfig.cc hier_code.h htcp.cc \
-	htcp.h http.cc HttpBody.h HttpBody.cc HttpHeader.cc \
-	HttpHeaderTools.cc HttpHdrCc.h HttpHdrCc.cc HttpHdrCc.cci \
-	HttpHdrContRange.cc HttpHdrRange.cc HttpHdrSc.cc \
+	SquidDns.h DnsLookupDetails.h DnsLookupDetails.cc dns.cc \
+	errorpage.cc ETag.cc EventLoop.h EventLoop.cc event.cc \
+	external_acl.cc ExternalACLEntry.cc FadingCounter.cc fd.cc \
+	fde.cc FileMap.h filemap.cc forward.cc fqdncache.cc ftp.cc \
+	gopher.cc helper.cc HelperChildConfig.h HelperChildConfig.cc \
+	hier_code.h htcp.cc htcp.h http.cc HttpBody.h HttpBody.cc \
+	HttpHeader.cc HttpHeaderTools.cc HttpHdrCc.h HttpHdrCc.cc \
+	HttpHdrCc.cci HttpHdrContRange.cc HttpHdrRange.cc HttpHdrSc.cc \
 	HttpHdrScTarget.cc HttpMsg.cc HttpParser.cc HttpParser.h \
 	HttpReply.cc HttpRequest.cc HttpRequestMethod.cc \
 	HttpStatusLine.cc icp_v2.cc icp_v3.cc ipc.cc ipc_win32.cc \
@@ -871,18 +877,18 @@
 	tests/stub_store_stats.cc time.cc tools.cc tunnel.cc \
 	MemStore.cc unlinkd.cc url.cc URLScheme.cc urn.cc wccp2.cc \
 	whois.cc win32.cc wordlist.cc
-am_tests_testEventLoop_OBJECTS = $(am__objects_4) BodyPipe.$(OBJEXT) \
-	CacheDigest.$(OBJEXT) cache_manager.$(OBJEXT) \
-	cache_cf.$(OBJEXT) carp.$(OBJEXT) cbdata.$(OBJEXT) \
-	ChunkedCodingParser.$(OBJEXT) client_db.$(OBJEXT) \
-	client_side.$(OBJEXT) client_side_reply.$(OBJEXT) \
-	client_side_request.$(OBJEXT) clientStream.$(OBJEXT) \
-	ConfigOption.$(OBJEXT) ConfigParser.$(OBJEXT) \
-	CpuAffinityMap.$(OBJEXT) CpuAffinitySet.$(OBJEXT) \
-	debug.$(OBJEXT) $(am__objects_6) $(am__objects_7) \
-	disk.$(OBJEXT) dlink.$(OBJEXT) $(am__objects_8) \
-	errorpage.$(OBJEXT) ETag.$(OBJEXT) EventLoop.$(OBJEXT) \
-	event.$(OBJEXT) external_acl.$(OBJEXT) \
+am_tests_testEventLoop_OBJECTS = AccessLogEntry.$(OBJEXT) \
+	$(am__objects_4) BodyPipe.$(OBJEXT) CacheDigest.$(OBJEXT) \
+	cache_manager.$(OBJEXT) cache_cf.$(OBJEXT) carp.$(OBJEXT) \
+	cbdata.$(OBJEXT) ChunkedCodingParser.$(OBJEXT) \
+	client_db.$(OBJEXT) client_side.$(OBJEXT) \
+	client_side_reply.$(OBJEXT) client_side_request.$(OBJEXT) \
+	clientStream.$(OBJEXT) ConfigOption.$(OBJEXT) \
+	ConfigParser.$(OBJEXT) CpuAffinityMap.$(OBJEXT) \
+	CpuAffinitySet.$(OBJEXT) debug.$(OBJEXT) $(am__objects_6) \
+	$(am__objects_7) disk.$(OBJEXT) dlink.$(OBJEXT) \
+	$(am__objects_8) errorpage.$(OBJEXT) ETag.$(OBJEXT) \
+	EventLoop.$(OBJEXT) event.$(OBJEXT) external_acl.$(OBJEXT) \
 	ExternalACLEntry.$(OBJEXT) FadingCounter.$(OBJEXT) \
 	fd.$(OBJEXT) fde.$(OBJEXT) filemap.$(OBJEXT) forward.$(OBJEXT) \
 	fqdncache.$(OBJEXT) ftp.$(OBJEXT) gopher.$(OBJEXT) \
@@ -965,9 +971,9 @@
 tests_testHttpReply_LINK = $(LIBTOOL) --tag=CXX $(AM_LIBTOOLFLAGS) \
 	$(LIBTOOLFLAGS) --mode=link $(CXXLD) $(AM_CXXFLAGS) \
 	$(CXXFLAGS) $(tests_testHttpReply_LDFLAGS) $(LDFLAGS) -o $@
-am__tests_testHttpRequest_SOURCES_DIST = AclRegs.cc AuthReg.cc \
-	HttpParser.cc HttpParser.h HttpRequest.cc HttpRequestMethod.cc \
-	mem.cc String.cc tests/testHttpRequest.h \
+am__tests_testHttpRequest_SOURCES_DIST = AccessLogEntry.cc AclRegs.cc \
+	AuthReg.cc HttpParser.cc HttpParser.h HttpRequest.cc \
+	HttpRequestMethod.cc mem.cc String.cc tests/testHttpRequest.h \
 	tests/testHttpRequest.cc tests/testHttpRequestMethod.h \
 	tests/testHttpRequestMethod.cc tests/testMain.cc \
 	tests/stub_DiskIOModule.cc tests/stub_main_cc.cc \
@@ -985,7 +991,7 @@
 	DelayTagged.cc DelayTagged.h DelayUser.cc DelayUser.h \
 	DelayVector.cc DelayVector.h NullDelayId.cc NullDelayId.h \
 	ClientDelayConfig.cc ClientDelayConfig.h disk.cc dlink.h \
-	dlink.cc dns_internal.cc DnsLookupDetails.h \
+	dlink.cc dns_internal.cc SquidDns.h DnsLookupDetails.h \
 	DnsLookupDetails.cc dns.cc errorpage.cc ETag.cc \
 	external_acl.cc ExternalACLEntry.cc fd.cc fde.cc forward.cc \
 	fqdncache.cc ftp.cc gopher.cc helper.cc HelperChildConfig.h \
@@ -1010,8 +1016,8 @@
 	StoreSwapLogData.cc event.cc tools.cc tunnel.cc SwapDir.cc \
 	MemStore.cc url.cc URLScheme.cc urn.cc wccp2.cc whois.cc \
 	FadingCounter.cc win32.cc wordlist.cc
-am_tests_testHttpRequest_OBJECTS = $(am__objects_4) \
-	HttpParser.$(OBJEXT) HttpRequest.$(OBJEXT) \
+am_tests_testHttpRequest_OBJECTS = AccessLogEntry.$(OBJEXT) \
+	$(am__objects_4) HttpParser.$(OBJEXT) HttpRequest.$(OBJEXT) \
 	HttpRequestMethod.$(OBJEXT) mem.$(OBJEXT) String.$(OBJEXT) \
 	tests/testHttpRequest.$(OBJEXT) \
 	tests/testHttpRequestMethod.$(OBJEXT) tests/testMain.$(OBJEXT) \
@@ -1335,24 +1341,25 @@
 tests_testString_LINK = $(LIBTOOL) --tag=CXX $(AM_LIBTOOLFLAGS) \
 	$(LIBTOOLFLAGS) --mode=link $(CXXLD) $(AM_CXXFLAGS) \
 	$(CXXFLAGS) $(tests_testString_LDFLAGS) $(LDFLAGS) -o $@
-am__tests_testURL_SOURCES_DIST = AclRegs.cc AuthReg.cc BodyPipe.cc \
-	cache_cf.cc cache_manager.cc CacheDigest.cc carp.cc cbdata.cc \
-	ChunkedCodingParser.cc client_db.cc client_side.cc \
-	client_side_reply.cc client_side_request.cc ClientInfo.h \
-	clientStream.cc ConfigOption.cc ConfigParser.cc \
-	CpuAffinityMap.cc CpuAffinityMap.h CpuAffinitySet.cc \
-	CpuAffinitySet.h CommonPool.h CompositePoolNode.h \
-	delay_pools.cc DelayId.cc DelayId.h DelayIdComposite.h \
-	DelayBucket.cc DelayBucket.h DelayConfig.cc DelayConfig.h \
-	DelayPool.cc DelayPool.h DelayPools.h DelaySpec.cc DelaySpec.h \
-	DelayTagged.cc DelayTagged.h DelayUser.cc DelayUser.h \
-	DelayVector.cc DelayVector.h NullDelayId.cc NullDelayId.h \
+am__tests_testURL_SOURCES_DIST = AccessLogEntry.cc AclRegs.cc \
+	AuthReg.cc BodyPipe.cc cache_cf.cc cache_manager.cc \
+	CacheDigest.cc carp.cc cbdata.cc ChunkedCodingParser.cc \
+	client_db.cc client_side.cc client_side_reply.cc \
+	client_side_request.cc ClientInfo.h clientStream.cc \
+	ConfigOption.cc ConfigParser.cc CpuAffinityMap.cc \
+	CpuAffinityMap.h CpuAffinitySet.cc CpuAffinitySet.h \
+	CommonPool.h CompositePoolNode.h delay_pools.cc DelayId.cc \
+	DelayId.h DelayIdComposite.h DelayBucket.cc DelayBucket.h \
+	DelayConfig.cc DelayConfig.h DelayPool.cc DelayPool.h \
+	DelayPools.h DelaySpec.cc DelaySpec.h DelayTagged.cc \
+	DelayTagged.h DelayUser.cc DelayUser.h DelayVector.cc \
+	DelayVector.h NullDelayId.cc NullDelayId.h \
 	ClientDelayConfig.cc ClientDelayConfig.h disk.cc \
 	DiskIO/ReadRequest.cc DiskIO/WriteRequest.cc dlink.h dlink.cc \
-	dns_internal.cc DnsLookupDetails.h DnsLookupDetails.cc dns.cc \
-	errorpage.cc ETag.cc event.cc external_acl.cc \
-	ExternalACLEntry.cc fd.cc fde.cc FileMap.h filemap.cc \
-	forward.cc fqdncache.cc ftp.cc gopher.cc helper.cc \
+	dns_internal.cc SquidDns.h DnsLookupDetails.h \
+	DnsLookupDetails.cc dns.cc errorpage.cc ETag.cc event.cc \
+	external_acl.cc ExternalACLEntry.cc fd.cc fde.cc FileMap.h \
+	filemap.cc forward.cc fqdncache.cc ftp.cc gopher.cc helper.cc \
 	HelperChildConfig.h HelperChildConfig.cc hier_code.h htcp.cc \
 	htcp.h http.cc HttpBody.h HttpBody.cc HttpHdrCc.h HttpHdrCc.cc \
 	HttpHdrCc.cci HttpHdrContRange.cc HttpHdrRange.cc HttpHdrSc.cc \
@@ -1379,8 +1386,8 @@
 	tests/testURLScheme.cc tests/testURLScheme.h tests/testMain.cc \
 	time.cc tools.cc tunnel.cc url.cc URLScheme.cc urn.cc wccp2.cc \
 	whois.cc FadingCounter.cc win32.cc wordlist.cc
-am_tests_testURL_OBJECTS = $(am__objects_4) BodyPipe.$(OBJEXT) \
-	cache_cf.$(OBJEXT) cache_manager.$(OBJEXT) \
+am_tests_testURL_OBJECTS = AccessLogEntry.$(OBJEXT) $(am__objects_4) \
+	BodyPipe.$(OBJEXT) cache_cf.$(OBJEXT) cache_manager.$(OBJEXT) \
 	CacheDigest.$(OBJEXT) carp.$(OBJEXT) cbdata.$(OBJEXT) \
 	ChunkedCodingParser.$(OBJEXT) client_db.$(OBJEXT) \
 	client_side.$(OBJEXT) client_side_reply.$(OBJEXT) \
@@ -1526,8 +1533,8 @@
 tests_testUfs_LINK = $(LIBTOOL) --tag=CXX $(AM_LIBTOOLFLAGS) \
 	$(LIBTOOLFLAGS) --mode=link $(CXXLD) $(AM_CXXFLAGS) \
 	$(CXXFLAGS) $(tests_testUfs_LDFLAGS) $(LDFLAGS) -o $@
-am__tests_test_http_range_SOURCES_DIST = AclRegs.cc AuthReg.cc \
-	BodyPipe.cc cache_cf.cc ProtoPort.cc ProtoPort.h \
+am__tests_test_http_range_SOURCES_DIST = AccessLogEntry.cc AclRegs.cc \
+	AuthReg.cc BodyPipe.cc cache_cf.cc ProtoPort.cc ProtoPort.h \
 	cache_manager.cc CacheDigest.cc carp.cc cbdata.cc \
 	ChunkedCodingParser.cc client_db.cc client_side.cc \
 	client_side_reply.cc client_side_request.cc ClientInfo.h \
@@ -1545,13 +1552,13 @@
 	DiskIO/WriteRequest.h DiskIO/DiskFile.h \
 	DiskIO/DiskIOStrategy.h DiskIO/IORequestor.h \
 	DiskIO/DiskIOModule.h disk.cc dlink.h dlink.cc dns_internal.cc \
-	DnsLookupDetails.h DnsLookupDetails.cc dns.cc errorpage.cc \
-	ETag.cc event.cc external_acl.cc ExternalACLEntry.cc \
-	FadingCounter.cc fd.cc fde.cc FileMap.h filemap.cc forward.cc \
-	fqdncache.cc ftp.cc gopher.cc helper.cc HelperChildConfig.h \
-	HelperChildConfig.cc hier_code.h htcp.cc htcp.h http.cc \
-	HttpBody.h HttpBody.cc HttpHdrCc.h HttpHdrCc.cc HttpHdrCc.cci \
-	HttpHdrContRange.cc HttpHdrRange.cc HttpHdrSc.cc \
+	SquidDns.h DnsLookupDetails.h DnsLookupDetails.cc dns.cc \
+	errorpage.cc ETag.cc event.cc external_acl.cc \
+	ExternalACLEntry.cc FadingCounter.cc fd.cc fde.cc FileMap.h \
+	filemap.cc forward.cc fqdncache.cc ftp.cc gopher.cc helper.cc \
+	HelperChildConfig.h HelperChildConfig.cc hier_code.h htcp.cc \
+	htcp.h http.cc HttpBody.h HttpBody.cc HttpHdrCc.h HttpHdrCc.cc \
+	HttpHdrCc.cci HttpHdrContRange.cc HttpHdrRange.cc HttpHdrSc.cc \
 	HttpHdrScTarget.cc HttpHeader.cc HttpHeaderTools.cc HttpMsg.cc \
 	HttpParser.cc HttpParser.h HttpReply.cc HttpRequest.cc \
 	HttpRequestMethod.cc HttpStatusLine.cc icp_v2.cc icp_v3.cc \
@@ -1574,8 +1581,9 @@
 	tests/stub_store_stats.cc time.cc tools.cc tunnel.cc \
 	unlinkd.cc url.cc URLScheme.cc urn.cc wccp2.cc whois.cc \
 	win32.cc wordlist.cc
-am_tests_test_http_range_OBJECTS = $(am__objects_4) BodyPipe.$(OBJEXT) \
-	cache_cf.$(OBJEXT) ProtoPort.$(OBJEXT) cache_manager.$(OBJEXT) \
+am_tests_test_http_range_OBJECTS = AccessLogEntry.$(OBJEXT) \
+	$(am__objects_4) BodyPipe.$(OBJEXT) cache_cf.$(OBJEXT) \
+	ProtoPort.$(OBJEXT) cache_manager.$(OBJEXT) \
 	CacheDigest.$(OBJEXT) carp.$(OBJEXT) cbdata.$(OBJEXT) \
 	ChunkedCodingParser.$(OBJEXT) client_db.$(OBJEXT) \
 	client_side.$(OBJEXT) client_side_reply.$(OBJEXT) \
@@ -1640,7 +1648,7 @@
 	StoreMetaVary.cc String.cc SquidNew.cc time.cc ufsdump.cc \
 	dlink.h dlink.cc HelperChildConfig.h \
 	tests/stub_HelperChildConfig.cc HttpRequestMethod.cc \
-	RemovalPolicy.cc squid.h win32.cc tests/stub_fd.cc
+	RemovalPolicy.cc squid-old.h win32.cc tests/stub_fd.cc
 am_ufsdump_OBJECTS = cbdata.$(OBJEXT) debug.$(OBJEXT) int.$(OBJEXT) \
 	mem.$(OBJEXT) MemBuf.$(OBJEXT) store_key_md5.$(OBJEXT) \
 	StoreMeta.$(OBJEXT) StoreMetaMD5.$(OBJEXT) \
@@ -1655,8 +1663,7 @@
 ufsdump_OBJECTS = $(am_ufsdump_OBJECTS) $(nodist_ufsdump_OBJECTS)
 am_unlinkd_OBJECTS = unlinkd_daemon.$(OBJEXT)
 unlinkd_OBJECTS = $(am_unlinkd_OBJECTS)
-unlinkd_DEPENDENCIES = ipc/libipc.la ip/libip.la $(am__DEPENDENCIES_2) \
-	$(am__DEPENDENCIES_3)
+unlinkd_DEPENDENCIES = $(am__DEPENDENCIES_2) $(am__DEPENDENCIES_3)
 DEFAULT_INCLUDES = 
 depcomp = $(SHELL) $(top_srcdir)/cfgaux/depcomp
 am__depfiles_maybe = depfiles
@@ -2034,12 +2041,12 @@
 COMPAT_LIB = -L$(top_builddir)/compat -lcompat-squid $(LIBPROFILER)
 subst_perlshell = sed -e 's,[@]PERL[@],$(PERL),g' <$(srcdir)/$@.pl.in >$@ || ($(RM) -f $@ ; exit 1)
 AUTOMAKE_OPTIONS = subdir-objects
-@USE_DNSSERVER_FALSE@DNSSOURCE = dns_internal.cc DnsLookupDetails.h \
-@USE_DNSSERVER_FALSE@	DnsLookupDetails.cc
-@USE_DNSSERVER_TRUE@DNSSOURCE = dns.cc DnsLookupDetails.h \
-@USE_DNSSERVER_TRUE@	DnsLookupDetails.cc
-@USE_DNSSERVER_FALSE@DNSSERVER = 
-@USE_DNSSERVER_TRUE@DNSSERVER = dnsserver
+@ENABLE_DNSHELPER_FALSE@DNSSOURCE = dns_internal.cc SquidDns.h \
+@ENABLE_DNSHELPER_FALSE@	DnsLookupDetails.h DnsLookupDetails.cc
+@ENABLE_DNSHELPER_TRUE@DNSSOURCE = dns.cc SquidDns.h \
+@ENABLE_DNSHELPER_TRUE@	DnsLookupDetails.h DnsLookupDetails.cc
+@ENABLE_DNSHELPER_FALSE@DNSHELPER = 
+@ENABLE_DNSHELPER_TRUE@DNSHELPER = dnsserver
 SBUF_SOURCE = \
 	base/InstanceId.h \
 	MemBlob.h \
@@ -2174,19 +2181,20 @@
 	DescriptorSet.h \
 	SquidConfig.cc
 
-squid_SOURCES = $(ACL_REGISTRATION_SOURCES) AccessLogEntry.h \
-	AsyncEngine.cc AsyncEngine.h cache_cf.cc ProtoPort.cc \
-	ProtoPort.h CacheDigest.cc cache_manager.cc CacheManager.h \
-	carp.cc cbdata.cc cbdata.h ChunkedCodingParser.cc \
-	ChunkedCodingParser.h client_db.cc client_side.cc \
-	client_side.h client_side_reply.cc client_side_reply.h \
-	client_side_request.cc client_side_request.h ClientInfo.h \
-	BodyPipe.cc BodyPipe.h ClientInfo.h ClientRequestContext.h \
-	clientStream.cc clientStream.h CommIO.h \
-	CompletionDispatcher.cc CompletionDispatcher.h CommRead.h \
-	ConfigOption.cc ConfigParser.cc ConfigParser.h CpuAffinity.cc \
-	CpuAffinity.h CpuAffinityMap.cc CpuAffinityMap.h \
-	CpuAffinitySet.cc CpuAffinitySet.h debug.cc Debug.h defines.h \
+squid_SOURCES = $(ACL_REGISTRATION_SOURCES) AccessLogEntry.cc \
+	AccessLogEntry.h AsyncEngine.cc AsyncEngine.h cache_cf.cc \
+	ProtoPort.cc ProtoPort.h CacheDigest.cc cache_manager.cc \
+	CacheManager.h carp.cc cbdata.cc cbdata.h \
+	ChunkedCodingParser.cc ChunkedCodingParser.h client_db.cc \
+	client_side.cc client_side.h client_side_reply.cc \
+	client_side_reply.h client_side_request.cc \
+	client_side_request.h ClientInfo.h BodyPipe.cc BodyPipe.h \
+	ClientInfo.h ClientRequestContext.h clientStream.cc \
+	clientStream.h CommIO.h CompletionDispatcher.cc \
+	CompletionDispatcher.h CommRead.h ConfigOption.cc \
+	ConfigParser.cc ConfigParser.h CpuAffinity.cc CpuAffinity.h \
+	CpuAffinityMap.cc CpuAffinityMap.h CpuAffinitySet.cc \
+	CpuAffinitySet.h debug.cc Debug.h defines.h \
 	$(DELAY_POOL_SOURCE) disk.cc $(DISKIO_SOURCE) dlink.h dlink.cc \
 	$(DNSSOURCE) enums.h err_type.h err_detail_type.h errorpage.cc \
 	errorpage.h ETag.cc ETag.h event.cc event.h EventLoop.h \
@@ -2214,7 +2222,7 @@
 	peer_proxy_negotiate_auth.cc peer_select.cc peer_sourcehash.cc \
 	peer_userhash.cc PeerSelectState.h PingData.h protos.h \
 	redirect.cc refresh.cc RemovalPolicy.cc RemovalPolicy.h \
-	send-announce.cc $(SBUF_SOURCE) $(SNMP_SOURCE) squid.h \
+	send-announce.cc $(SBUF_SOURCE) $(SNMP_SOURCE) squid-old.h \
 	SquidMath.h SquidMath.cc SquidNew.cc stat.cc StatHist.cc \
 	String.cc stmem.cc stmem.h store.cc Store.h StoreFileSystem.cc \
 	StoreFileSystem.h StoreHashIndex.h store_io.cc StoreIOBuffer.h \
@@ -2322,8 +2330,6 @@
 @USE_LOADABLE_MODULES_TRUE@squid_LDFLAGS = -export-dynamic -dlopen force
 unlinkd_SOURCES = unlinkd_daemon.cc
 unlinkd_LDADD = \
-	ipc/libipc.la \
-	ip/libip.la \
 	$(COMPAT_LIB) \
 	$(XTRA_LIBS)
 
@@ -2359,7 +2365,7 @@
 	tests/stub_HelperChildConfig.cc \
 	HttpRequestMethod.cc \
 	RemovalPolicy.cc \
-	squid.h \
+	squid-old.h \
 	$(WIN32_SOURCE) \
 	tests/stub_fd.cc
 
@@ -2755,6 +2761,7 @@
 	$(SQUID_CPPUNIT_LA)
 
 tests_testCacheManager_SOURCES = \
+	AccessLogEntry.cc \
 	$(ACL_REGISTRATION_SOURCES) \
 	debug.cc \
 	HttpParser.cc \
@@ -3092,6 +3099,7 @@
 	$(SQUID_CPPUNIT_LA)
 
 tests_testEvent_SOURCES = \
+	AccessLogEntry.cc \
 	$(ACL_REGISTRATION_SOURCES) \
 	BodyPipe.cc \
 	CacheDigest.cc \
@@ -3284,6 +3292,7 @@
 	$(SQUID_CPPUNIT_LA)
 
 tests_testEventLoop_SOURCES = \
+	AccessLogEntry.cc \
 	$(ACL_REGISTRATION_SOURCES) \
 	BodyPipe.cc \
 	CacheDigest.cc \
@@ -3475,6 +3484,7 @@
 	$(SQUID_CPPUNIT_LA)
 
 tests_test_http_range_SOURCES = \
+	AccessLogEntry.cc \
 	$(ACL_REGISTRATION_SOURCES) \
 	BodyPipe.cc \
 	cache_cf.cc \
@@ -3697,6 +3707,7 @@
 	$(SQUID_CPPUNIT_LA)
 
 tests_testHttpRequest_SOURCES = \
+	AccessLogEntry.cc \
 	$(ACL_REGISTRATION_SOURCES) \
 	HttpParser.cc \
 	HttpParser.h \
@@ -4606,6 +4617,7 @@
 	$(SWAP_TEST_DS)
 
 tests_testURL_SOURCES = \
+	AccessLogEntry.cc \
 	$(ACL_REGISTRATION_SOURCES) \
 	BodyPipe.cc \
 	cache_cf.cc \
@@ -5475,6 +5487,7 @@
 distclean-compile:
 	-rm -f *.tab.c
 
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/AccessLogEntry.Po@am__quote@
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/AclRegs.Po@am__quote@
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/AsyncEngine.Po@am__quote@
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/AuthReg.Po@am__quote@
diff -u -r -N squid-3.2.0.14/src/MemBlob.cc squid-3.2.0.15/src/MemBlob.cc
--- squid-3.2.0.14/src/MemBlob.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/MemBlob.cc	2012-02-06 04:52:31.000000000 +1300
@@ -29,7 +29,7 @@
  */
 
 
-#include "config.h"
+#include "squid.h"
 #include "base/TextException.h"
 #include "Debug.h"
 #include "Mem.h"
diff -u -r -N squid-3.2.0.14/src/MemBuf.cc squid-3.2.0.15/src/MemBuf.cc
--- squid-3.2.0.14/src/MemBuf.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/MemBuf.cc	2012-02-06 04:52:31.000000000 +1300
@@ -101,7 +101,7 @@
 
 /* if you have configure you can use this */
 #if defined(HAVE_CONFIG_H)
-#include "config.h"
+#include "squid.h"
 #endif
 
 #ifdef VA_COPY
@@ -113,7 +113,7 @@
 #define VA_COPY __va_copy
 #endif
 
-#include "squid.h"
+#include "squid-old.h"
 #include "MemBuf.h"
 
 /* local constants */
diff -u -r -N squid-3.2.0.14/src/mem.cc squid-3.2.0.15/src/mem.cc
--- squid-3.2.0.14/src/mem.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/mem.cc	2012-02-06 04:52:31.000000000 +1300
@@ -32,7 +32,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "event.h"
 #include "mgr/Registration.h"
 #include "ClientInfo.h"
diff -u -r -N squid-3.2.0.14/src/mem_node.cc squid-3.2.0.15/src/mem_node.cc
--- squid-3.2.0.14/src/mem_node.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/mem_node.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "mem_node.h"
 
 static ptrdiff_t makeMemNodeDataOffset();
diff -u -r -N squid-3.2.0.14/src/MemObject.cc squid-3.2.0.15/src/MemObject.cc
--- squid-3.2.0.14/src/MemObject.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/MemObject.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "comm/Connection.h"
 #include "MemObject.h"
 #include "HttpRequest.h"
@@ -492,3 +492,9 @@
 }
 
 #endif
+
+int64_t
+MemObject::availableForSwapOut() const
+{
+    return endOffset() - swapout.queue_offset;
+}
diff -u -r -N squid-3.2.0.14/src/MemObject.h squid-3.2.0.15/src/MemObject.h
--- squid-3.2.0.14/src/MemObject.h	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/MemObject.h	2012-02-06 04:52:31.000000000 +1300
@@ -81,6 +81,7 @@
      */
     int64_t objectBytesOnDisk() const;
     int64_t policyLowestOffsetToKeep(bool swap) const;
+    int64_t availableForSwapOut() const; ///< buffered bytes we have not swapped out yet
     void trimSwappable();
     void trimUnSwappable();
     bool isContiguous() const;
diff -u -r -N squid-3.2.0.14/src/MemStore.cc squid-3.2.0.15/src/MemStore.cc
--- squid-3.2.0.14/src/MemStore.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/MemStore.cc	2012-02-06 04:52:31.000000000 +1300
@@ -5,7 +5,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 #include "base/RunnersRegistry.h"
 #include "ipc/mem/Page.h"
 #include "ipc/mem/Pages.h"
@@ -347,7 +347,7 @@
 int64_t
 MemStore::EntryLimit()
 {
-    if (!Config.memMaxSize)
+    if (!Config.memShared || !Config.memMaxSize)
         return 0; // no memory cache configured
 
     const int64_t entrySize = Ipc::Mem::PageSize(); // for now
@@ -374,26 +374,17 @@
 }
 
 
-/// initializes shared memory segments used by MemStore
-class MemStoreRr: public Ipc::Mem::RegisteredRunner
+/// decides whether to use a shared memory cache or checks its configuration
+class MemStoreCfgRr: public ::RegisteredRunner
 {
 public:
     /* RegisteredRunner API */
-    MemStoreRr(): owner(NULL) {}
     virtual void run(const RunnerRegistry &);
-    virtual ~MemStoreRr();
-
-protected:
-    virtual void create(const RunnerRegistry &);
-
-private:
-    MemStoreMap::Owner *owner;
 };
 
-RunnerRegistrationEntry(rrAfterConfig, MemStoreRr);
-
+RunnerRegistrationEntry(rrFinalizeConfig, MemStoreCfgRr);
 
-void MemStoreRr::run(const RunnerRegistry &r)
+void MemStoreCfgRr::run(const RunnerRegistry &r)
 {
     // decide whether to use a shared memory cache if the user did not specify
     if (!Config.memShared.configured()) {
@@ -409,7 +400,31 @@
         debugs(20, DBG_IMPORTANT, "WARNING: memory_cache_shared is on, but only"
                " a single worker is running");
     }
+}
+
+
+/// initializes shared memory segments used by MemStore
+class MemStoreRr: public Ipc::Mem::RegisteredRunner
+{
+public:
+    /* RegisteredRunner API */
+    MemStoreRr(): owner(NULL) {}
+    virtual void run(const RunnerRegistry &);
+    virtual ~MemStoreRr();
+
+protected:
+    virtual void create(const RunnerRegistry &);
 
+private:
+    MemStoreMap::Owner *owner;
+};
+
+RunnerRegistrationEntry(rrAfterConfig, MemStoreRr);
+
+
+void MemStoreRr::run(const RunnerRegistry &r)
+{
+    assert(Config.memShared.configured());
     Ipc::Mem::RegisteredRunner::run(r);
 }
 
diff -u -r -N squid-3.2.0.14/src/mgr/Action.cc squid-3.2.0.15/src/mgr/Action.cc
--- squid-3.2.0.14/src/mgr/Action.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/mgr/Action.cc	2012-02-06 04:52:31.000000000 +1300
@@ -5,7 +5,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 #include "comm/Connection.h"
 #include "HttpReply.h"
 #include "ipc/Port.h"
@@ -102,6 +102,15 @@
     if (writeHttpHeader) {
         HttpReply *rep = new HttpReply;
         rep->setHeaders(HTTP_OK, NULL, "text/plain", -1, squid_curtime, squid_curtime);
+        // Allow cachemgr and other XHR scripts access to our version string
+        const ActionParams &params = command().params;
+        if (params.httpOrigin.size() > 0) {
+            rep->header.putExt("Access-Control-Allow-Origin", params.httpOrigin.termedBuf());
+#if HAVE_AUTH_MODULE_BASIC
+            rep->header.putExt("Access-Control-Allow-Credentials","true");
+#endif
+            rep->header.putExt("Access-Control-Expose-Headers","Server");
+        }
         entry->replaceHttpReply(rep);
     }
 
diff -u -r -N squid-3.2.0.14/src/mgr/ActionParams.cc squid-3.2.0.15/src/mgr/ActionParams.cc
--- squid-3.2.0.14/src/mgr/ActionParams.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/mgr/ActionParams.cc	2012-02-06 04:52:31.000000000 +1300
@@ -5,7 +5,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 #include "base/TextException.h"
 #include "ipc/TypedMsgHdr.h"
 #include "mgr/ActionParams.h"
@@ -23,6 +23,7 @@
     httpMethod = static_cast<_method_t>(m);
 
     msg.getPod(httpFlags);
+    msg.getString(httpOrigin);
 
     msg.getString(actionName);
     msg.getString(userName);
@@ -36,6 +37,7 @@
     msg.putString(httpUri);
     msg.putInt(httpMethod);
     msg.putPod(httpFlags);
+    msg.putString(httpOrigin);
 
     msg.putString(actionName);
     msg.putString(userName);
diff -u -r -N squid-3.2.0.14/src/mgr/ActionParams.h squid-3.2.0.15/src/mgr/ActionParams.h
--- squid-3.2.0.14/src/mgr/ActionParams.h	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/mgr/ActionParams.h	2012-02-06 04:52:31.000000000 +1300
@@ -29,6 +29,7 @@
     String httpUri; ///< HTTP request URI
     _method_t httpMethod; ///< HTTP request method
     request_flags httpFlags; ///< HTTP request flags
+    String httpOrigin;       ///< HTTP Origin: header (if any)
 
     /* action parameters extracted from the client HTTP request */
     String actionName; ///< action name (and credentials realm)
diff -u -r -N squid-3.2.0.14/src/mgr/ActionWriter.cc squid-3.2.0.15/src/mgr/ActionWriter.cc
--- squid-3.2.0.14/src/mgr/ActionWriter.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/mgr/ActionWriter.cc	2012-02-06 04:52:31.000000000 +1300
@@ -5,7 +5,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 #include "base/TextException.h"
 #include "comm/Connection.h"
 #include "mgr/ActionWriter.h"
diff -u -r -N squid-3.2.0.14/src/mgr/BasicActions.cc squid-3.2.0.15/src/mgr/BasicActions.cc
--- squid-3.2.0.14/src/mgr/BasicActions.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/mgr/BasicActions.cc	2012-02-06 04:52:31.000000000 +1300
@@ -5,7 +5,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 #include "base/TextException.h"
 #include "CacheManager.h"
 #include "mgr/ActionCreator.h"
@@ -15,6 +15,23 @@
 #include "Store.h"
 
 
+Mgr::IndexAction::Pointer
+Mgr::IndexAction::Create(const Command::Pointer &cmd)
+{
+    return new IndexAction(cmd);
+}
+
+Mgr::IndexAction::IndexAction(const Command::Pointer &cmd): Action(cmd)
+{
+    debugs(16, 5, HERE);
+}
+
+void
+Mgr::IndexAction::dump(StoreEntry* entry)
+{
+    debugs(16, 5, HERE);
+}
+
 Mgr::MenuAction::Pointer
 Mgr::MenuAction::Create(const Command::Pointer &cmd)
 {
@@ -128,9 +145,10 @@
 void
 Mgr::RegisterBasics()
 {
+    RegisterAction("index", "Cache Manager Interface", &Mgr::IndexAction::Create, 0, 1);
+    RegisterAction("menu", "Cache Manager Menu", &Mgr::MenuAction::Create, 0, 1);
     RegisterAction("offline_toggle", "Toggle offline_mode setting", &Mgr::OfflineToggleAction::Create, 1, 1);
     RegisterAction("shutdown", "Shut Down the Squid Process", &Mgr::ShutdownAction::Create, 1, 1);
     RegisterAction("reconfigure", "Reconfigure Squid", &Mgr::ReconfigureAction::Create, 1, 1);
     RegisterAction("rotate", "Rotate Squid Logs", &Mgr::RotateAction::Create, 1, 1);
-    RegisterAction("menu", "Cache Manager Menu", &Mgr::MenuAction::Create, 0, 1);
 }
diff -u -r -N squid-3.2.0.14/src/mgr/BasicActions.h squid-3.2.0.15/src/mgr/BasicActions.h
--- squid-3.2.0.14/src/mgr/BasicActions.h	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/mgr/BasicActions.h	2012-02-06 04:52:31.000000000 +1300
@@ -16,6 +16,22 @@
 namespace Mgr
 {
 
+/// A dummy action placeholder for the no-action requests
+/// a templated Cache Manager index ('home') page.
+/// Display output is produced directly by the receiving worker
+/// without invoking the co-ordinator or action Job.
+class IndexAction: public Action
+{
+public:
+    static Pointer Create(const CommandPointer &cmd);
+    /* Action API */
+    virtual void dump(StoreEntry *entry);
+
+protected:
+    IndexAction(const CommandPointer &cmd);
+};
+
+
 /// returns available Cache Manager actions and their access requirements
 class MenuAction: public Action
 {
diff -u -r -N squid-3.2.0.14/src/mgr/Command.cc squid-3.2.0.15/src/mgr/Command.cc
--- squid-3.2.0.14/src/mgr/Command.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/mgr/Command.cc	2012-02-06 04:52:31.000000000 +1300
@@ -5,7 +5,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 #include "mgr/ActionProfile.h"
 #include "mgr/Command.h"
 
diff -u -r -N squid-3.2.0.14/src/mgr/CountersAction.cc squid-3.2.0.15/src/mgr/CountersAction.cc
--- squid-3.2.0.14/src/mgr/CountersAction.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/mgr/CountersAction.cc	2012-02-06 04:52:31.000000000 +1300
@@ -5,7 +5,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 #include "base/TextException.h"
 #include "ipc/Messages.h"
 #include "ipc/TypedMsgHdr.h"
diff -u -r -N squid-3.2.0.14/src/mgr/Filler.cc squid-3.2.0.15/src/mgr/Filler.cc
--- squid-3.2.0.14/src/mgr/Filler.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/mgr/Filler.cc	2012-02-06 04:52:31.000000000 +1300
@@ -5,7 +5,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 #include "base/TextException.h"
 #include "comm/Connection.h"
 #include "mgr/Filler.h"
diff -u -r -N squid-3.2.0.14/src/mgr/Forwarder.cc squid-3.2.0.15/src/mgr/Forwarder.cc
--- squid-3.2.0.14/src/mgr/Forwarder.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/mgr/Forwarder.cc	2012-02-06 04:52:31.000000000 +1300
@@ -5,7 +5,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 #include "base/AsyncJobCalls.h"
 #include "base/TextException.h"
 #include "CommCalls.h"
diff -u -r -N squid-3.2.0.14/src/mgr/FunAction.cc squid-3.2.0.15/src/mgr/FunAction.cc
--- squid-3.2.0.14/src/mgr/FunAction.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/mgr/FunAction.cc	2012-02-06 04:52:31.000000000 +1300
@@ -5,7 +5,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 #include "base/TextException.h"
 #include "comm/Connection.h"
 #include "ipc/UdsOp.h"
diff -u -r -N squid-3.2.0.14/src/mgr/InfoAction.cc squid-3.2.0.15/src/mgr/InfoAction.cc
--- squid-3.2.0.14/src/mgr/InfoAction.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/mgr/InfoAction.cc	2012-02-06 04:52:31.000000000 +1300
@@ -5,7 +5,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 #include "base/TextException.h"
 #include "comm/Connection.h"
 #include "HttpReply.h"
diff -u -r -N squid-3.2.0.14/src/mgr/Inquirer.cc squid-3.2.0.15/src/mgr/Inquirer.cc
--- squid-3.2.0.14/src/mgr/Inquirer.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/mgr/Inquirer.cc	2012-02-06 04:52:31.000000000 +1300
@@ -5,7 +5,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 #include "base/TextException.h"
 #include "comm/Connection.h"
 #include "comm/Write.h"
diff -u -r -N squid-3.2.0.14/src/mgr/IntervalAction.cc squid-3.2.0.15/src/mgr/IntervalAction.cc
--- squid-3.2.0.14/src/mgr/IntervalAction.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/mgr/IntervalAction.cc	2012-02-06 04:52:31.000000000 +1300
@@ -5,7 +5,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 #include "base/TextException.h"
 #include "ipc/Messages.h"
 #include "ipc/TypedMsgHdr.h"
diff -u -r -N squid-3.2.0.14/src/mgr/IntParam.cc squid-3.2.0.15/src/mgr/IntParam.cc
--- squid-3.2.0.14/src/mgr/IntParam.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/mgr/IntParam.cc	2012-02-06 04:52:31.000000000 +1300
@@ -5,7 +5,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 #include "base/TextException.h"
 #include "ipc/TypedMsgHdr.h"
 #include "mgr/IntParam.h"
diff -u -r -N squid-3.2.0.14/src/mgr/IoAction.cc squid-3.2.0.15/src/mgr/IoAction.cc
--- squid-3.2.0.14/src/mgr/IoAction.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/mgr/IoAction.cc	2012-02-06 04:52:31.000000000 +1300
@@ -5,7 +5,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 #include "base/TextException.h"
 #include "ipc/Messages.h"
 #include "ipc/TypedMsgHdr.h"
diff -u -r -N squid-3.2.0.14/src/mgr/QueryParams.cc squid-3.2.0.15/src/mgr/QueryParams.cc
--- squid-3.2.0.14/src/mgr/QueryParams.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/mgr/QueryParams.cc	2012-02-06 04:52:31.000000000 +1300
@@ -5,7 +5,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 #include "base/TextException.h"
 #include "ipc/TypedMsgHdr.h"
 #include "mgr/IntParam.h"
diff -u -r -N squid-3.2.0.14/src/mgr/Registration.cc squid-3.2.0.15/src/mgr/Registration.cc
--- squid-3.2.0.14/src/mgr/Registration.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/mgr/Registration.cc	2012-02-06 04:52:31.000000000 +1300
@@ -5,7 +5,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 #include "CacheManager.h"
 #include "mgr/Registration.h"
 
diff -u -r -N squid-3.2.0.14/src/mgr/Request.cc squid-3.2.0.15/src/mgr/Request.cc
--- squid-3.2.0.14/src/mgr/Request.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/mgr/Request.cc	2012-02-06 04:52:31.000000000 +1300
@@ -5,7 +5,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 #include "base/TextException.h"
 #include "comm/Connection.h"
 #include "ipc/Messages.h"
diff -u -r -N squid-3.2.0.14/src/mgr/Response.cc squid-3.2.0.15/src/mgr/Response.cc
--- squid-3.2.0.14/src/mgr/Response.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/mgr/Response.cc	2012-02-06 04:52:31.000000000 +1300
@@ -5,7 +5,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 #include "base/TextException.h"
 #include "CacheManager.h"
 #include "ipc/Messages.h"
diff -u -r -N squid-3.2.0.14/src/mgr/ServiceTimesAction.cc squid-3.2.0.15/src/mgr/ServiceTimesAction.cc
--- squid-3.2.0.14/src/mgr/ServiceTimesAction.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/mgr/ServiceTimesAction.cc	2012-02-06 04:52:31.000000000 +1300
@@ -5,7 +5,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 #include "base/TextException.h"
 #include "ipc/Messages.h"
 #include "ipc/TypedMsgHdr.h"
diff -u -r -N squid-3.2.0.14/src/mgr/StoreIoAction.cc squid-3.2.0.15/src/mgr/StoreIoAction.cc
--- squid-3.2.0.14/src/mgr/StoreIoAction.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/mgr/StoreIoAction.cc	2012-02-06 04:52:31.000000000 +1300
@@ -5,7 +5,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 #include "base/TextException.h"
 #include "ipc/Messages.h"
 #include "ipc/TypedMsgHdr.h"
diff -u -r -N squid-3.2.0.14/src/mgr/StoreToCommWriter.cc squid-3.2.0.15/src/mgr/StoreToCommWriter.cc
--- squid-3.2.0.14/src/mgr/StoreToCommWriter.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/mgr/StoreToCommWriter.cc	2012-02-06 04:52:31.000000000 +1300
@@ -5,7 +5,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 #include "base/TextException.h"
 #include "comm/Connection.h"
 #include "CommCalls.h"
diff -u -r -N squid-3.2.0.14/src/mgr/StringParam.cc squid-3.2.0.15/src/mgr/StringParam.cc
--- squid-3.2.0.14/src/mgr/StringParam.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/mgr/StringParam.cc	2012-02-06 04:52:31.000000000 +1300
@@ -5,7 +5,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 #include "ipc/TypedMsgHdr.h"
 #include "mgr/StringParam.h"
 
diff -u -r -N squid-3.2.0.14/src/mgr/stub_libmgr.cc squid-3.2.0.15/src/mgr/stub_libmgr.cc
--- squid-3.2.0.14/src/mgr/stub_libmgr.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/mgr/stub_libmgr.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "config.h"
+#include "squid.h"
 
 #define STUB_API "lmgr/libmgr.la"
 #include "tests/STUB.h"
diff -u -r -N squid-3.2.0.14/src/mime.cc squid-3.2.0.15/src/mime.cc
--- squid-3.2.0.14/src/mime.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/mime.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "HttpHdrCc.h"
 #include "Store.h"
 #include "StoreClient.h"
diff -u -r -N squid-3.2.0.14/src/mime_header.cc squid-3.2.0.15/src/mime_header.cc
--- squid-3.2.0.14/src/mime_header.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/mime_header.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 
 #define GET_HDR_SZ 1024
 
diff -u -r -N squid-3.2.0.14/src/mk-string-arrays.awk squid-3.2.0.15/src/mk-string-arrays.awk
--- squid-3.2.0.14/src/mk-string-arrays.awk	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/mk-string-arrays.awk	2012-02-06 04:52:31.000000000 +1300
@@ -14,7 +14,7 @@
 	print "/*"
 	print " * Auto-Generated File. Changes will be destroyed."
 	print " */"
-	print "#include \"config.h\""
+	print "#include \"squid.h\""
         codeSkip = 1
         e = 0
         nspath = ""
diff -u -r -N squid-3.2.0.14/src/multicast.cc squid-3.2.0.15/src/multicast.cc
--- squid-3.2.0.14/src/multicast.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/multicast.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "comm/Connection.h"
 // XXX: for icpIncomingConn - need to pass it as a generic parameter.
 #include "ICP.h"
diff -u -r -N squid-3.2.0.14/src/neighbors.cc squid-3.2.0.15/src/neighbors.cc
--- squid-3.2.0.14/src/neighbors.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/neighbors.cc	2012-02-06 04:52:31.000000000 +1300
@@ -30,7 +30,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "ProtoPort.h"
 #include "acl/FilledChecklist.h"
 #include "comm/Connection.h"
diff -u -r -N squid-3.2.0.14/src/NullDelayId.cc squid-3.2.0.15/src/NullDelayId.cc
--- squid-3.2.0.14/src/NullDelayId.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/NullDelayId.cc	2012-02-06 04:52:31.000000000 +1300
@@ -37,10 +37,10 @@
  * Copyright (c) 2003, Robert Collins <robertc@squid-cache.org>
  */
 
-#include "config.h"
+#include "squid.h"
 
 #if USE_DELAY_POOLS
-#include "squid.h"
+#include "squid-old.h"
 #include "NullDelayId.h"
 #include "DelayPools.h"
 
diff -u -r -N squid-3.2.0.14/src/NullDelayId.h squid-3.2.0.15/src/NullDelayId.h
--- squid-3.2.0.14/src/NullDelayId.h	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/NullDelayId.h	2012-02-06 04:52:31.000000000 +1300
@@ -39,7 +39,7 @@
 #ifndef NULLDELAYID_H
 #define NULLDELAYID_H
 #if USE_DELAY_POOLS
-#include "squid.h"
+#include "squid-old.h"
 #include "RefCount.h"
 #include "DelayIdComposite.h"
 
diff -u -r -N squid-3.2.0.14/src/Packer.cc squid-3.2.0.15/src/Packer.cc
--- squid-3.2.0.14/src/Packer.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/Packer.cc	2012-02-06 04:52:31.000000000 +1300
@@ -71,7 +71,7 @@
  */
 
 
-#include "squid.h"
+#include "squid-old.h"
 #include "Store.h"
 #include "MemBuf.h"
 
diff -u -r -N squid-3.2.0.14/src/Parsing.cc squid-3.2.0.15/src/Parsing.cc
--- squid-3.2.0.14/src/Parsing.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/Parsing.cc	2012-02-06 04:52:31.000000000 +1300
@@ -32,7 +32,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 #include "compat/strtoll.h"
 #include "Parsing.h"
 
diff -u -r -N squid-3.2.0.14/src/Parsing.h squid-3.2.0.15/src/Parsing.h
--- squid-3.2.0.14/src/Parsing.h	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/Parsing.h	2012-02-06 04:52:31.000000000 +1300
@@ -36,7 +36,7 @@
 #ifndef SQUID_PARSING_H
 #define SQUID_PARSING_H
 
-#include "squid.h"
+#include "squid-old.h"
 
 extern double xatof(const char *token);
 extern int xatoi(const char *token);
diff -u -r -N squid-3.2.0.14/src/pconn.cc squid-3.2.0.15/src/pconn.cc
--- squid-3.2.0.14/src/pconn.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/pconn.cc	2012-02-06 04:52:31.000000000 +1300
@@ -32,7 +32,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "comm/Connection.h"
 #include "mgr/Registration.h"
 #include "Store.h"
diff -u -r -N squid-3.2.0.14/src/peer_digest.cc squid-3.2.0.15/src/peer_digest.cc
--- squid-3.2.0.14/src/peer_digest.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/peer_digest.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #if USE_CACHE_DIGESTS
 
 #include "event.h"
diff -u -r -N squid-3.2.0.14/src/PeerDigest.h squid-3.2.0.15/src/PeerDigest.h
--- squid-3.2.0.14/src/PeerDigest.h	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/PeerDigest.h	2012-02-06 04:52:31.000000000 +1300
@@ -34,7 +34,7 @@
 #ifndef   SQUID_PEERDIGEST_H
 #define   SQUID_PEERDIGEST_H
 
-#include "squid.h"
+#include "squid-old.h"
 
 #if USE_CACHE_DIGESTS
 
diff -u -r -N squid-3.2.0.14/src/peer_proxy_negotiate_auth.cc squid-3.2.0.15/src/peer_proxy_negotiate_auth.cc
--- squid-3.2.0.14/src/peer_proxy_negotiate_auth.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/peer_proxy_negotiate_auth.cc	2012-02-06 04:52:31.000000000 +1300
@@ -25,7 +25,7 @@
  * Hosted at http://sourceforge.net/projects/squidkerbauth
  */
 
-#include "config.h"
+#include "squid.h"
 #include "base64.h"
 #include "Debug.h"
 
diff -u -r -N squid-3.2.0.14/src/peer_select.cc squid-3.2.0.15/src/peer_select.cc
--- squid-3.2.0.14/src/peer_select.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/peer_select.cc	2012-02-06 04:52:31.000000000 +1300
@@ -32,7 +32,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "DnsLookupDetails.h"
 #include "errorpage.h"
 #include "event.h"
@@ -320,7 +320,7 @@
             psstate->paths->push_back(p);
         }
     } else {
-        debugs(44, 3, HERE << "Unknown host: " << fs->_peer ? fs->_peer->host : psstate->request->GetHost());
+        debugs(44, 3, HERE << "Unknown host: " << (fs->_peer ? fs->_peer->host : psstate->request->GetHost()));
         // discard any previous error.
         delete psstate->lastError;
         psstate->lastError = NULL;
diff -u -r -N squid-3.2.0.14/src/peer_sourcehash.cc squid-3.2.0.15/src/peer_sourcehash.cc
--- squid-3.2.0.14/src/peer_sourcehash.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/peer_sourcehash.cc	2012-02-06 04:52:31.000000000 +1300
@@ -34,7 +34,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "Store.h"
 #include "HttpRequest.h"
 #include "mgr/Registration.h"
diff -u -r -N squid-3.2.0.14/src/peer_userhash.cc squid-3.2.0.15/src/peer_userhash.cc
--- squid-3.2.0.14/src/peer_userhash.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/peer_userhash.cc	2012-02-06 04:52:31.000000000 +1300
@@ -34,7 +34,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 
 #if USE_AUTH
 
diff -u -r -N squid-3.2.0.14/src/ProfStats.cc squid-3.2.0.15/src/ProfStats.cc
--- squid-3.2.0.14/src/ProfStats.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/ProfStats.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 
 #if USE_XPROF_STATS
 
diff -u -r -N squid-3.2.0.14/src/ProtoPort.cc squid-3.2.0.15/src/ProtoPort.cc
--- squid-3.2.0.14/src/ProtoPort.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/ProtoPort.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,7 +1,3 @@
-/*
- * $Id$
- */
-
 #include "squid.h"
 #include "comm.h"
 #include "ProtoPort.h"
@@ -12,7 +8,6 @@
 http_port_list::http_port_list(const char *aProtocol)
 #if USE_SSL
         :
-        http(*this),
         dynamicCertMemCacheSize(std::numeric_limits<size_t>::max())
 #endif
 {
@@ -42,12 +37,3 @@
     safe_free(sslContextSessionId);
 #endif
 }
-
-
-#if USE_SSL
-
-https_port_list::https_port_list(): http_port_list("https")
-{
-}
-
-#endif
diff -u -r -N squid-3.2.0.14/src/ProtoPort.h squid-3.2.0.15/src/ProtoPort.h
--- squid-3.2.0.14/src/ProtoPort.h	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/ProtoPort.h	2012-02-06 04:52:31.000000000 +1300
@@ -51,9 +51,6 @@
     Comm::ConnectionPointer listenConn;
 
 #if USE_SSL
-    // XXX: temporary hack to ease move of SSL options to http_port
-    http_port_list &http;
-
     char *cert;
     char *key;
     int version;
@@ -78,13 +75,4 @@
     CBDATA_CLASS2(http_port_list);
 };
 
-
-#if USE_SSL
-
-struct https_port_list: public http_port_list {
-    https_port_list();
-};
-
-#endif
-
 #endif /* SQUID_PROTO_PORT_H */
diff -u -r -N squid-3.2.0.14/src/protos.h squid-3.2.0.15/src/protos.h
--- squid-3.2.0.14/src/protos.h	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/protos.h	2012-02-06 04:52:31.000000000 +1300
@@ -125,17 +125,6 @@
 SQUIDCEXTERN void file_read(int, char *, int, off_t, DRCB *, void *);
 SQUIDCEXTERN void disk_init(void);
 
-SQUIDCEXTERN void dnsShutdown(void);
-SQUIDCEXTERN void dnsInit(void);
-SQUIDCEXTERN void dnsSubmit(const char *lookup, HLPCB * callback, void *data);
-
-/* dns_internal.c */
-SQUIDCEXTERN void idnsInit(void);
-SQUIDCEXTERN void idnsShutdown(void);
-SQUIDCEXTERN void idnsALookup(const char *, IDNSCB *, void *);
-
-SQUIDCEXTERN void idnsPTRLookup(const Ip::Address &, IDNSCB *, void *);
-
 SQUIDCEXTERN void fd_close(int fd);
 SQUIDCEXTERN void fd_open(int fd, unsigned int type, const char *);
 SQUIDCEXTERN void fd_note(int fd, const char *);
@@ -264,11 +253,7 @@
 extern variable_list *snmp_prfPeerFn(variable_list *, snint *);
 extern variable_list *snmp_netIpFn(variable_list *, snint *);
 extern variable_list *snmp_netFqdnFn(variable_list *, snint *);
-#if USE_DNSSERVERS
 extern variable_list *snmp_netDnsFn(variable_list *, snint *);
-#else
-extern variable_list *snmp_netIdnsFn(variable_list *, snint *);
-#endif /* USE_DNSSERVERS */
 extern variable_list *snmp_meshPtblFn(variable_list *, snint *);
 extern variable_list *snmp_meshCtblFn(variable_list *, snint *);
 #endif /* SQUID_SNMP */
diff -u -r -N squid-3.2.0.14/src/recv-announce.cc squid-3.2.0.15/src/recv-announce.cc
--- squid-3.2.0.14/src/recv-announce.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/recv-announce.cc	2012-02-06 04:52:31.000000000 +1300
@@ -31,7 +31,7 @@
  *  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111, USA.
  *
  */
-#include "config.h"
+#include "squid.h"
 
 #include <stdio.h>
 #include <fcntl.h>
diff -u -r -N squid-3.2.0.14/src/redirect.cc squid-3.2.0.15/src/redirect.cc
--- squid-3.2.0.14/src/redirect.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/redirect.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #if USE_AUTH
 #include "auth/UserRequest.h"
 #endif
diff -u -r -N squid-3.2.0.14/src/refresh.cc squid-3.2.0.15/src/refresh.cc
--- squid-3.2.0.14/src/refresh.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/refresh.cc	2012-02-06 04:52:31.000000000 +1300
@@ -37,7 +37,7 @@
 #define USE_POSIX_REGEX		/* put before includes; always use POSIX */
 #endif
 
-#include "squid.h"
+#include "squid-old.h"
 #include "HttpHdrCc.h"
 #include "mgr/Registration.h"
 #include "Store.h"
diff -u -r -N squid-3.2.0.14/src/RemovalPolicy.cc squid-3.2.0.15/src/RemovalPolicy.cc
--- squid-3.2.0.14/src/RemovalPolicy.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/RemovalPolicy.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 #include "RemovalPolicy.h"
 
 CBDATA_CLASS_INIT(RemovalPolicy);
diff -u -r -N squid-3.2.0.14/src/RemovalPolicy.h squid-3.2.0.15/src/RemovalPolicy.h
--- squid-3.2.0.14/src/RemovalPolicy.h	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/RemovalPolicy.h	2012-02-06 04:52:31.000000000 +1300
@@ -35,7 +35,7 @@
 #ifndef   SQUID_REMOVALPOLICY_H
 #define   SQUID_REMOVALPOLICY_H
 
-#include "squid.h"
+#include "squid-old.h"
 #include "cbdata.h"
 
 class RemovalPolicyWalker;
diff -u -r -N squid-3.2.0.14/src/repl/heap/store_heap_replacement.cc squid-3.2.0.15/src/repl/heap/store_heap_replacement.cc
--- squid-3.2.0.14/src/repl/heap/store_heap_replacement.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/repl/heap/store_heap_replacement.cc	2012-02-06 04:52:31.000000000 +1300
@@ -41,7 +41,7 @@
  *  http://www.hpl.hp.com/techreports/1999/HPL-1999-69.html
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "heap.h"
 #include "store_heap_replacement.h"
 #include "Store.h"
diff -u -r -N squid-3.2.0.14/src/repl/heap/store_repl_heap.cc squid-3.2.0.15/src/repl/heap/store_repl_heap.cc
--- squid-3.2.0.14/src/repl/heap/store_repl_heap.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/repl/heap/store_repl_heap.cc	2012-02-06 04:52:31.000000000 +1300
@@ -41,7 +41,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "heap.h"
 #include "store_heap_replacement.h"
 #include "Store.h"
diff -u -r -N squid-3.2.0.14/src/repl/lru/store_repl_lru.cc squid-3.2.0.15/src/repl/lru/store_repl_lru.cc
--- squid-3.2.0.14/src/repl/lru/store_repl_lru.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/repl/lru/store_repl_lru.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "Store.h"
 #include "MemObject.h"
 #include "SquidTime.h"
diff -u -r -N squid-3.2.0.14/src/send-announce.cc squid-3.2.0.15/src/send-announce.cc
--- squid-3.2.0.14/src/send-announce.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/send-announce.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "comm/Connection.h"
 #include "event.h"
 #include "fde.h"
diff -u -r -N squid-3.2.0.14/src/Server.cc squid-3.2.0.15/src/Server.cc
--- squid-3.2.0.14/src/Server.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/Server.cc	2012-02-06 04:52:31.000000000 +1300
@@ -32,7 +32,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "acl/Gadgets.h"
 #include "base/TextException.h"
 #include "comm/Connection.h"
diff -u -r -N squid-3.2.0.14/src/snmp/Forwarder.cc squid-3.2.0.15/src/snmp/Forwarder.cc
--- squid-3.2.0.14/src/snmp/Forwarder.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/snmp/Forwarder.cc	2012-02-06 04:52:31.000000000 +1300
@@ -5,7 +5,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 #include "base/TextException.h"
 #include "CommCalls.h"
 #include "comm.h"
diff -u -r -N squid-3.2.0.14/src/snmp/Inquirer.cc squid-3.2.0.15/src/snmp/Inquirer.cc
--- squid-3.2.0.14/src/snmp/Inquirer.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/snmp/Inquirer.cc	2012-02-06 04:52:31.000000000 +1300
@@ -5,7 +5,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 #include "base/TextException.h"
 #include "CommCalls.h"
 #include "comm.h"
diff -u -r -N squid-3.2.0.14/src/snmp/Pdu.cc squid-3.2.0.15/src/snmp/Pdu.cc
--- squid-3.2.0.14/src/snmp/Pdu.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/snmp/Pdu.cc	2012-02-06 04:52:31.000000000 +1300
@@ -5,7 +5,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 #include "base/TextException.h"
 #include "ipc/TypedMsgHdr.h"
 #include "protos.h"
diff -u -r -N squid-3.2.0.14/src/snmp/Request.cc squid-3.2.0.15/src/snmp/Request.cc
--- squid-3.2.0.14/src/snmp/Request.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/snmp/Request.cc	2012-02-06 04:52:31.000000000 +1300
@@ -5,7 +5,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 #include "ipc/Messages.h"
 #include "ipc/TypedMsgHdr.h"
 #include "snmp/Request.h"
diff -u -r -N squid-3.2.0.14/src/snmp/Response.cc squid-3.2.0.15/src/snmp/Response.cc
--- squid-3.2.0.14/src/snmp/Response.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/snmp/Response.cc	2012-02-06 04:52:31.000000000 +1300
@@ -5,7 +5,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 #include "base/TextException.h"
 #include "ipc/Messages.h"
 #include "ipc/TypedMsgHdr.h"
diff -u -r -N squid-3.2.0.14/src/snmp/Session.cc squid-3.2.0.15/src/snmp/Session.cc
--- squid-3.2.0.14/src/snmp/Session.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/snmp/Session.cc	2012-02-06 04:52:31.000000000 +1300
@@ -5,7 +5,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 #include "base/TextException.h"
 #include "ipc/TypedMsgHdr.h"
 #include "protos.h"
diff -u -r -N squid-3.2.0.14/src/snmp/Var.cc squid-3.2.0.15/src/snmp/Var.cc
--- squid-3.2.0.14/src/snmp/Var.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/snmp/Var.cc	2012-02-06 04:52:31.000000000 +1300
@@ -5,7 +5,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 #include "base/TextException.h"
 #include "ipc/TypedMsgHdr.h"
 #include "protos.h"
diff -u -r -N squid-3.2.0.14/src/snmp_agent.cc squid-3.2.0.15/src/snmp_agent.cc
--- squid-3.2.0.14/src/snmp_agent.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/snmp_agent.cc	2012-02-06 04:52:31.000000000 +1300
@@ -32,7 +32,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "cache_snmp.h"
 #include "Store.h"
 #include "mem_node.h"
diff -u -r -N squid-3.2.0.14/src/snmp_core.cc squid-3.2.0.15/src/snmp_core.cc
--- squid-3.2.0.14/src/snmp_core.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/snmp_core.cc	2012-02-06 04:52:31.000000000 +1300
@@ -29,7 +29,7 @@
  *  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111, USA.
  *
  */
-#include "squid.h"
+#include "squid-old.h"
 #include "acl/FilledChecklist.h"
 #include "base/CbcPointer.h"
 #include "comm.h"
@@ -236,15 +236,9 @@
     snmpAddNodeStr("1.3.6.1.4.1.3495.1.4.2", FQDN_GHBN, snmp_netFqdnFn, static_Inst, atSum);
 
     snmpAddNodeStr("1.3.6.1.4.1.3495.1.4", NET_DNS_CACHE, NULL, NULL);
-#if USE_DNSSERVERS
     snmpAddNodeStr("1.3.6.1.4.1.3495.1.4.3", DNS_REQ, snmp_netDnsFn, static_Inst, atSum);
     snmpAddNodeStr("1.3.6.1.4.1.3495.1.4.3", DNS_REP, snmp_netDnsFn, static_Inst, atSum);
     snmpAddNodeStr("1.3.6.1.4.1.3495.1.4.3", DNS_SERVERS, snmp_netDnsFn, static_Inst, atSum);
-#else
-    snmpAddNodeStr("1.3.6.1.4.1.3495.1.4.3", DNS_REQ, snmp_netIdnsFn, static_Inst, atSum);
-    snmpAddNodeStr("1.3.6.1.4.1.3495.1.4.3", DNS_REP, snmp_netIdnsFn, static_Inst, atSum);
-    snmpAddNodeStr("1.3.6.1.4.1.3495.1.4.3", DNS_SERVERS, snmp_netIdnsFn, static_Inst, atSum);
-#endif
 
     /* SQ_MESH - 1.3.6.1.4.1.3495.1.5 */
     snmpAddNodeStr("1.3.6.1.4.1.3495.1", 5, NULL, NULL);
diff -u -r -N squid-3.2.0.14/src/SquidConfig.cc squid-3.2.0.15/src/SquidConfig.cc
--- squid-3.2.0.14/src/SquidConfig.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/SquidConfig.cc	2012-02-06 04:52:31.000000000 +1300
@@ -2,7 +2,7 @@
  * $Id$
  */
 
-#include "config.h"
+#include "squid.h"
 #include "ip/Address.h"
 // just for the global definition of Config and Config2
 #include "structs.h"
diff -u -r -N squid-3.2.0.14/src/SquidDns.h squid-3.2.0.15/src/SquidDns.h
--- squid-3.2.0.14/src/SquidDns.h	1970-01-01 12:00:00.000000000 +1200
+++ squid-3.2.0.15/src/SquidDns.h	2012-02-06 04:52:31.000000000 +1300
@@ -0,0 +1,22 @@
+#ifndef SQUID_DNS_H
+#define SQUID_DNS_H
+
+namespace Ip
+{
+class Address;
+}
+
+// generic DNS API
+extern void dnsInit(void);
+extern void dnsShutdown(void);
+
+#if USE_DNSHELPER
+// external DNS helper API
+extern void dnsSubmit(const char *lookup, HLPCB * callback, void *data);
+#else
+// internal DNS client API
+extern void idnsALookup(const char *, IDNSCB *, void *);
+extern void idnsPTRLookup(const Ip::Address &, IDNSCB *, void *);
+#endif
+
+#endif /* SQUID_DNS_H */
diff -u -r -N squid-3.2.0.14/src/squid.h squid-3.2.0.15/src/squid.h
--- squid-3.2.0.14/src/squid.h	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/squid.h	1970-01-01 12:00:00.000000000 +1200
@@ -1,189 +0,0 @@
-/*
- * AUTHOR: Duane Wessels
- *
- * SQUID Web Proxy Cache          http://www.squid-cache.org/
- * ----------------------------------------------------------
- *
- *  Squid is the result of efforts by numerous individuals from
- *  the Internet community; see the CONTRIBUTORS file for full
- *  details.   Many organizations have provided support for Squid's
- *  development; see the SPONSORS file for full details.  Squid is
- *  Copyrighted (C) 2001 by the Regents of the University of
- *  California; see the COPYRIGHT file for full details.  Squid
- *  incorporates software developed and/or copyrighted by other
- *  sources; see the CREDITS file for full details.
- *
- *  This program is free software; you can redistribute it and/or modify
- *  it under the terms of the GNU General Public License as published by
- *  the Free Software Foundation; either version 2 of the License, or
- *  (at your option) any later version.
- *
- *  This program is distributed in the hope that it will be useful,
- *  but WITHOUT ANY WARRANTY; without even the implied warranty of
- *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- *  GNU General Public License for more details.
- *
- *  You should have received a copy of the GNU General Public License
- *  along with this program; if not, write to the Free Software
- *  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111, USA.
- *
- */
-
-#ifndef SQUID_H
-#define SQUID_H
-
-#include "config.h"
-
-#if _SQUID_MSWIN_
-/** \cond AUTODOCS-IGNORE */
-using namespace Squid;
-/** \endcond */
-#endif
-
-#if HAVE_UNISTD_H
-#include <unistd.h>
-#endif
-#if HAVE_STDIO_H
-#include <stdio.h>
-#endif
-#if HAVE_CTYPE_H
-#include <ctype.h>
-#endif
-#if HAVE_ERRNO_H
-#include <errno.h>
-#endif
-#if HAVE_GRP_H
-#include <grp.h>
-#endif
-#if HAVE_GNUMALLOC_H
-#include <gnumalloc.h>
-#elif HAVE_MALLOC_H
-#include <malloc.h>
-#endif
-#if HAVE_MEMORY_H
-#include <memory.h>
-#endif
-#if HAVE_NETDB_H
-#include <netdb.h>
-#endif
-#if HAVE_PATHS_H
-#include <paths.h>
-#endif
-#if HAVE_PWD_H
-#include <pwd.h>
-#endif
-#if HAVE_SIGNAL_H
-#include <signal.h>
-#endif
-#if HAVE_TIME_H
-#include <time.h>
-#endif
-#if HAVE_SYS_PARAM_H
-#include <sys/param.h>
-#endif
-#if HAVE_SYS_TIME_H
-#include <sys/time.h>
-#endif
-#if HAVE_SYS_RESOURCE_H
-#include <sys/resource.h>	/* needs sys/time.h above it */
-#endif
-#if HAVE_SYS_SOCKET_H
-#include <sys/socket.h>
-#endif
-#if HAVE_NETINET_IN_H
-#include <netinet/in.h>
-#endif
-#if HAVE_ARPA_INET_H
-#include <arpa/inet.h>
-#endif
-#if HAVE_SYS_STAT_H
-#include <sys/stat.h>
-#endif
-#if HAVE_SYS_UN_H
-#include <sys/un.h>
-#endif
-#if HAVE_SYS_WAIT_H
-#include <sys/wait.h>
-#endif
-#if HAVE_LIBC_H
-#include <libc.h>
-#endif
-#if HAVE_SYS_SYSCALL_H
-#include <sys/syscall.h>
-#endif
-#if HAVE_STRING_H
-#include <string.h>
-#endif
-#if HAVE_STRINGS_H
-#include <strings.h>
-#endif
-#if HAVE_BSTRING_H
-#include <bstring.h>
-#endif
-#if HAVE_GETOPT_H
-#include <getopt.h>
-#endif
-#if HAVE_LIMITS_H
-#include <limits.h>
-#endif
-#if _SQUID_WINDOWS_
-#include <io.h>
-#endif
-#if HAVE_SYS_MOUNT_H
-#include <sys/mount.h>
-#endif
-#if HAVE_MATH_H
-#include <math.h>
-#endif
-
-#ifndef MAXPATHLEN
-#define MAXPATHLEN SQUID_MAXPATHLEN
-#endif
-
-#if LEAK_CHECK_MODE
-#define LOCAL_ARRAY(type,name,size) \
-        static type *local_##name=NULL; \
-        type *name = local_##name ? local_##name : \
-                ( local_##name = (type *)xcalloc(size, sizeof(type)) )
-#else
-#define LOCAL_ARRAY(type,name,size) static type name[size]
-#endif
-
-#if _SQUID_NEXT_ && !defined(S_ISDIR)
-#define S_ISDIR(mode) (((mode) & (_S_IFMT)) == (_S_IFDIR))
-#endif
-
-#include "md5.h"
-#if SQUID_SNMP
-#include "cache_snmp.h"
-#endif
-#include "hash.h"
-#include "rfc3596.h"
-#include "defines.h"
-#include "enums.h"
-#include "typedefs.h"
-#include "util.h"
-#include "profiler/Profiler.h"
-#include "MemPool.h"
-#include "ip/Address.h"
-#include "structs.h"
-#include "protos.h"
-#include "globals.h"
-
-/*
- * I'm sick of having to keep doing this ..
- */
-#define INDEXSD(i)   (Config.cacheSwap.swapDirs[(i)].getRaw())
-
-#define FD_READ_METHOD(fd, buf, len) (*fd_table[fd].read_method)(fd, buf, len)
-#define FD_WRITE_METHOD(fd, buf, len) (*fd_table[fd].write_method)(fd, buf, len)
-
-#ifndef IPPROTO_UDP
-#define IPPROTO_UDP 0
-#endif
-
-#ifndef IPPROTO_TCP
-#define IPPROTO_TCP 0
-#endif
-
-#endif /* SQUID_H */
diff -u -r -N squid-3.2.0.14/src/SquidMath.cc squid-3.2.0.15/src/SquidMath.cc
--- squid-3.2.0.14/src/SquidMath.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/SquidMath.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "config.h"
+#include "squid.h"
 #include "SquidMath.h"
 
 int
diff -u -r -N squid-3.2.0.14/src/SquidNew.cc squid-3.2.0.15/src/SquidNew.cc
--- squid-3.2.0.14/src/SquidNew.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/SquidNew.cc	2012-02-06 04:52:31.000000000 +1300
@@ -35,7 +35,7 @@
 
 #define _SQUID_EXTERNNEW_
 
-#include "squid.h"
+#include "squid-old.h"
 
 
 #ifdef __SUNPRO_CC
diff -u -r -N squid-3.2.0.14/src/squid-old.h squid-3.2.0.15/src/squid-old.h
--- squid-3.2.0.14/src/squid-old.h	1970-01-01 12:00:00.000000000 +1200
+++ squid-3.2.0.15/src/squid-old.h	2012-02-06 04:52:31.000000000 +1300
@@ -0,0 +1,189 @@
+/*
+ * AUTHOR: Duane Wessels
+ *
+ * SQUID Web Proxy Cache          http://www.squid-cache.org/
+ * ----------------------------------------------------------
+ *
+ *  Squid is the result of efforts by numerous individuals from
+ *  the Internet community; see the CONTRIBUTORS file for full
+ *  details.   Many organizations have provided support for Squid's
+ *  development; see the SPONSORS file for full details.  Squid is
+ *  Copyrighted (C) 2001 by the Regents of the University of
+ *  California; see the COPYRIGHT file for full details.  Squid
+ *  incorporates software developed and/or copyrighted by other
+ *  sources; see the CREDITS file for full details.
+ *
+ *  This program is free software; you can redistribute it and/or modify
+ *  it under the terms of the GNU General Public License as published by
+ *  the Free Software Foundation; either version 2 of the License, or
+ *  (at your option) any later version.
+ *
+ *  This program is distributed in the hope that it will be useful,
+ *  but WITHOUT ANY WARRANTY; without even the implied warranty of
+ *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ *  GNU General Public License for more details.
+ *
+ *  You should have received a copy of the GNU General Public License
+ *  along with this program; if not, write to the Free Software
+ *  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111, USA.
+ *
+ */
+
+#ifndef SQUID_H
+#define SQUID_H
+
+#include "squid.h"
+
+#if _SQUID_MSWIN_
+/** \cond AUTODOCS-IGNORE */
+using namespace Squid;
+/** \endcond */
+#endif
+
+#if HAVE_UNISTD_H
+#include <unistd.h>
+#endif
+#if HAVE_STDIO_H
+#include <stdio.h>
+#endif
+#if HAVE_CTYPE_H
+#include <ctype.h>
+#endif
+#if HAVE_ERRNO_H
+#include <errno.h>
+#endif
+#if HAVE_GRP_H
+#include <grp.h>
+#endif
+#if HAVE_GNUMALLOC_H
+#include <gnumalloc.h>
+#elif HAVE_MALLOC_H
+#include <malloc.h>
+#endif
+#if HAVE_MEMORY_H
+#include <memory.h>
+#endif
+#if HAVE_NETDB_H
+#include <netdb.h>
+#endif
+#if HAVE_PATHS_H
+#include <paths.h>
+#endif
+#if HAVE_PWD_H
+#include <pwd.h>
+#endif
+#if HAVE_SIGNAL_H
+#include <signal.h>
+#endif
+#if HAVE_TIME_H
+#include <time.h>
+#endif
+#if HAVE_SYS_PARAM_H
+#include <sys/param.h>
+#endif
+#if HAVE_SYS_TIME_H
+#include <sys/time.h>
+#endif
+#if HAVE_SYS_RESOURCE_H
+#include <sys/resource.h>	/* needs sys/time.h above it */
+#endif
+#if HAVE_SYS_SOCKET_H
+#include <sys/socket.h>
+#endif
+#if HAVE_NETINET_IN_H
+#include <netinet/in.h>
+#endif
+#if HAVE_ARPA_INET_H
+#include <arpa/inet.h>
+#endif
+#if HAVE_SYS_STAT_H
+#include <sys/stat.h>
+#endif
+#if HAVE_SYS_UN_H
+#include <sys/un.h>
+#endif
+#if HAVE_SYS_WAIT_H
+#include <sys/wait.h>
+#endif
+#if HAVE_LIBC_H
+#include <libc.h>
+#endif
+#if HAVE_SYS_SYSCALL_H
+#include <sys/syscall.h>
+#endif
+#if HAVE_STRING_H
+#include <string.h>
+#endif
+#if HAVE_STRINGS_H
+#include <strings.h>
+#endif
+#if HAVE_BSTRING_H
+#include <bstring.h>
+#endif
+#if HAVE_GETOPT_H
+#include <getopt.h>
+#endif
+#if HAVE_LIMITS_H
+#include <limits.h>
+#endif
+#if _SQUID_WINDOWS_
+#include <io.h>
+#endif
+#if HAVE_SYS_MOUNT_H
+#include <sys/mount.h>
+#endif
+#if HAVE_MATH_H
+#include <math.h>
+#endif
+
+#ifndef MAXPATHLEN
+#define MAXPATHLEN SQUID_MAXPATHLEN
+#endif
+
+#if LEAK_CHECK_MODE
+#define LOCAL_ARRAY(type,name,size) \
+        static type *local_##name=NULL; \
+        type *name = local_##name ? local_##name : \
+                ( local_##name = (type *)xcalloc(size, sizeof(type)) )
+#else
+#define LOCAL_ARRAY(type,name,size) static type name[size]
+#endif
+
+#if _SQUID_NEXT_ && !defined(S_ISDIR)
+#define S_ISDIR(mode) (((mode) & (_S_IFMT)) == (_S_IFDIR))
+#endif
+
+#include "md5.h"
+#if SQUID_SNMP
+#include "cache_snmp.h"
+#endif
+#include "hash.h"
+#include "rfc3596.h"
+#include "defines.h"
+#include "enums.h"
+#include "typedefs.h"
+#include "util.h"
+#include "profiler/Profiler.h"
+#include "MemPool.h"
+#include "ip/Address.h"
+#include "structs.h"
+#include "protos.h"
+#include "globals.h"
+
+/*
+ * I'm sick of having to keep doing this ..
+ */
+#define INDEXSD(i)   (Config.cacheSwap.swapDirs[(i)].getRaw())
+
+#define FD_READ_METHOD(fd, buf, len) (*fd_table[fd].read_method)(fd, buf, len)
+#define FD_WRITE_METHOD(fd, buf, len) (*fd_table[fd].write_method)(fd, buf, len)
+
+#ifndef IPPROTO_UDP
+#define IPPROTO_UDP 0
+#endif
+
+#ifndef IPPROTO_TCP
+#define IPPROTO_TCP 0
+#endif
+
+#endif /* SQUID_H */
diff -u -r -N squid-3.2.0.14/src/ssl/certificate_db.cc squid-3.2.0.15/src/ssl/certificate_db.cc
--- squid-3.2.0.14/src/ssl/certificate_db.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/ssl/certificate_db.cc	2012-02-06 04:52:31.000000000 +1300
@@ -2,7 +2,7 @@
  * $Id$
  */
 
-#include "config.h"
+#include "squid.h"
 #include "ssl/certificate_db.h"
 #if HAVE_ERRNO_H
 #include <errno.h>
diff -u -r -N squid-3.2.0.14/src/ssl/Config.cc squid-3.2.0.15/src/ssl/Config.cc
--- squid-3.2.0.14/src/ssl/Config.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/ssl/Config.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,7 +1,7 @@
 /*
  * $Id$
  */
-#include "config.h"
+#include "squid.h"
 #include "ssl/Config.h"
 
 Ssl::Config Ssl::TheConfig;
diff -u -r -N squid-3.2.0.14/src/ssl/context_storage.cc squid-3.2.0.15/src/ssl/context_storage.cc
--- squid-3.2.0.14/src/ssl/context_storage.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/ssl/context_storage.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,7 +1,7 @@
 /*
  * $Id$
  */
-#include "config.h"
+#include "squid.h"
 #include "Store.h"
 #include "StoreEntryStream.h"
 #include "ssl/context_storage.h"
diff -u -r -N squid-3.2.0.14/src/ssl/crtd_message.cc squid-3.2.0.15/src/ssl/crtd_message.cc
--- squid-3.2.0.14/src/ssl/crtd_message.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/ssl/crtd_message.cc	2012-02-06 04:52:31.000000000 +1300
@@ -2,7 +2,7 @@
  * $Id$
  */
 
-#include "config.h"
+#include "squid.h"
 #include "ssl/crtd_message.h"
 #if HAVE_CSTDLIB
 #include <cstdlib>
diff -u -r -N squid-3.2.0.14/src/ssl/ErrorDetail.cc squid-3.2.0.15/src/ssl/ErrorDetail.cc
--- squid-3.2.0.14/src/ssl/ErrorDetail.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/ssl/ErrorDetail.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "squid.h"
+#include "squid-old.h"
 #include "errorpage.h"
 #include "ssl/ErrorDetail.h"
 #if HAVE_MAP
diff -u -r -N squid-3.2.0.14/src/ssl/ErrorDetailManager.cc squid-3.2.0.15/src/ssl/ErrorDetailManager.cc
--- squid-3.2.0.14/src/ssl/ErrorDetailManager.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/ssl/ErrorDetailManager.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "squid.h"
+#include "squid-old.h"
 #include "ErrorDetail.h"
 #include "errorpage.h"
 #include "ErrorDetailManager.h"
@@ -20,7 +20,7 @@
 class ErrorDetailFile : public TemplateFile
 {
 public:
-    explicit ErrorDetailFile(ErrorDetailsList::Pointer const details): TemplateFile("error-details.txt") {
+    explicit ErrorDetailFile(ErrorDetailsList::Pointer const details): TemplateFile("error-details.txt", ERR_NONE) {
         buf.init();
         theDetails = details;
     }
diff -u -r -N squid-3.2.0.14/src/ssl/gadgets.cc squid-3.2.0.15/src/ssl/gadgets.cc
--- squid-3.2.0.14/src/ssl/gadgets.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/ssl/gadgets.cc	2012-02-06 04:52:31.000000000 +1300
@@ -2,7 +2,7 @@
  * $Id$
  */
 
-#include "config.h"
+#include "squid.h"
 #include "ssl/gadgets.h"
 #if HAVE_OPENSSL_X509V3_H
 #include <openssl/x509v3.h>
diff -u -r -N squid-3.2.0.14/src/ssl/helper.cc squid-3.2.0.15/src/ssl/helper.cc
--- squid-3.2.0.14/src/ssl/helper.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/ssl/helper.cc	2012-02-06 04:52:31.000000000 +1300
@@ -2,7 +2,7 @@
  * 2008/11/14
  */
 
-#include "config.h"
+#include "squid.h"
 #include "ProtoPort.h"
 #include "ssl/Config.h"
 #include "ssl/helper.h"
diff -u -r -N squid-3.2.0.14/src/ssl/ssl_crtd.cc squid-3.2.0.15/src/ssl/ssl_crtd.cc
--- squid-3.2.0.14/src/ssl/ssl_crtd.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/ssl/ssl_crtd.cc	2012-02-06 04:52:31.000000000 +1300
@@ -2,7 +2,7 @@
  * $Id$
  */
 
-#include "config.h"
+#include "squid.h"
 #include "helpers/defines.h"
 #include "ssl/gadgets.h"
 #include "ssl/crtd_message.h"
diff -u -r -N squid-3.2.0.14/src/ssl/stub_libsslsquid.cc squid-3.2.0.15/src/ssl/stub_libsslsquid.cc
--- squid-3.2.0.14/src/ssl/stub_libsslsquid.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/ssl/stub_libsslsquid.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "config.h"
+#include "squid.h"
 #include "fatal.h"
 
 /* Stub File for the ssl/libsslsquid.la convenience library */
diff -u -r -N squid-3.2.0.14/src/ssl/stub_libsslutil.cc squid-3.2.0.15/src/ssl/stub_libsslutil.cc
--- squid-3.2.0.14/src/ssl/stub_libsslutil.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/ssl/stub_libsslutil.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "config.h"
+#include "squid.h"
 #include "fatal.h"
 
 /* Stub File for the ssl/libsslutil.la convenience library */
diff -u -r -N squid-3.2.0.14/src/ssl/support.cc squid-3.2.0.15/src/ssl/support.cc
--- squid-3.2.0.14/src/ssl/support.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/ssl/support.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 
 /* MS Visual Studio Projects are monolithic, so we need the following
  * #if to exclude the SSL code from compile process when not needed.
@@ -333,7 +333,7 @@
 #endif
 #if SSL_OP_ALL
     {
-        "ALL", SSL_OP_ALL
+        "ALL", (long)SSL_OP_ALL
     },
 #endif
 #if SSL_OP_SINGLE_DH_USE
@@ -403,7 +403,7 @@
 static long
 ssl_parse_options(const char *options)
 {
-    long op = SSL_OP_ALL;
+    long op = 0;
     char *tmp;
     char *option;
 
diff -u -r -N squid-3.2.0.14/src/stat.cc squid-3.2.0.15/src/stat.cc
--- squid-3.2.0.14/src/stat.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/stat.cc	2012-02-06 04:52:31.000000000 +1300
@@ -32,7 +32,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "event.h"
 #include "format/Token.h"
 #include "StoreClient.h"
diff -u -r -N squid-3.2.0.14/src/stmem.cc squid-3.2.0.15/src/stmem.cc
--- squid-3.2.0.14/src/stmem.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/stmem.cc	2012-02-06 04:52:31.000000000 +1300
@@ -34,7 +34,7 @@
  * Copyright (c) 2003, Robert Collins <robertc@squid-cache.org>
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "stmem.h"
 #include "mem_node.h"
 #include "MemObject.h"
diff -u -r -N squid-3.2.0.14/src/store.cc squid-3.2.0.15/src/store.cc
--- squid-3.2.0.14/src/store.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/store.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "CacheManager.h"
 #include "comm/Connection.h"
 #include "ETag.h"
@@ -1890,95 +1890,8 @@
     return result;
 }
 
-bool
-StoreEntry::swapoutPossible()
-{
-    if (!Config.cacheSwap.n_configured)
-        return false;
-
-    /* should we swap something out to disk? */
-    debugs(20, 7, "storeSwapOut: " << url());
-    debugs(20, 7, "storeSwapOut: store_status = " << storeStatusStr[store_status]);
-
-    assert(mem_obj);
-    MemObject::SwapOut::Decision &decision = mem_obj->swapout.decision;
-
-    // if we decided that swapout is not possible, do not repeat same checks
-    if (decision == MemObject::SwapOut::swImpossible) {
-        debugs(20, 3, "storeSwapOut: already rejected");
-        return false;
-    }
-
-    // this flag may change so we must check it even if we already said "yes"
-    if (EBIT_TEST(flags, ENTRY_ABORTED)) {
-        assert(EBIT_TEST(flags, RELEASE_REQUEST));
-        // StoreEntry::abort() already closed the swap out file, if any
-        decision = MemObject::SwapOut::swImpossible;
-        return false;
-    }
-
-    // if we decided that swapout is possible, do not repeat same checks
-    if (decision == MemObject::SwapOut::swPossible) {
-        debugs(20, 3, "storeSwapOut: already allowed");
-        return true;
-    }
-
-    // if we are swapping out already, do not repeat same checks
-    if (swap_status != SWAPOUT_NONE) {
-        debugs(20, 3, "storeSwapOut: already started");
-        decision = MemObject::SwapOut::swPossible;
-        return true;
-    }
-
-    if (!checkCachable()) {
-        debugs(20, 3, "storeSwapOut: not cachable");
-        decision = MemObject::SwapOut::swImpossible;
-        return false;
-    }
-
-    if (EBIT_TEST(flags, ENTRY_SPECIAL)) {
-        debugs(20, 3, "storeSwapOut: " << url() << " SPECIAL");
-        decision = MemObject::SwapOut::swImpossible;
-        return false;
-    }
-
-    // check cache_dir max-size limit if all cache_dirs have it
-    if (store_maxobjsize >= 0) {
-        // TODO: add estimated store metadata size to be conservative
-
-        // use guaranteed maximum if it is known
-        const int64_t expectedEnd = mem_obj->expectedReplySize();
-        debugs(20, 7, "storeSwapOut: expectedEnd = " << expectedEnd);
-        if (expectedEnd > store_maxobjsize) {
-            debugs(20, 3, "storeSwapOut: will not fit: " << expectedEnd <<
-                   " > " << store_maxobjsize);
-            decision = MemObject::SwapOut::swImpossible;
-            return false; // known to outgrow the limit eventually
-        }
-
-        // use current minimum (always known)
-        const int64_t currentEnd = mem_obj->endOffset();
-        if (currentEnd > store_maxobjsize) {
-            debugs(20, 3, "storeSwapOut: does not fit: " << currentEnd <<
-                   " > " << store_maxobjsize);
-            decision = MemObject::SwapOut::swImpossible;
-            return false; // already does not fit and may only get bigger
-        }
-
-        // prevent default swPossible answer for yet unknown length
-        if (expectedEnd < 0) {
-            debugs(20, 3, "storeSwapOut: wait for more info: " <<
-                   store_maxobjsize);
-            return false; // may fit later, but will be rejected now
-        }
-    }
-
-    decision = MemObject::SwapOut::swPossible;
-    return true;
-}
-
 void
-StoreEntry::trimMemory()
+StoreEntry::trimMemory(const bool preserveSwappable)
 {
     /*
      * DPW 2007-05-09
@@ -1988,7 +1901,7 @@
     if (mem_status == IN_MEMORY)
         return;
 
-    if (!swapOutAble()) {
+    if (!preserveSwappable) {
         if (mem_obj->policyLowestOffsetToKeep(0) == 0) {
             /* Nothing to do */
             return;
diff -u -r -N squid-3.2.0.14/src/store_client.cc squid-3.2.0.15/src/store_client.cc
--- squid-3.2.0.14/src/store_client.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/store_client.cc	2012-02-06 04:52:31.000000000 +1300
@@ -34,7 +34,7 @@
  * Portions copyright (c) 2003 Robert Collins <robertc@squid-cache.org>
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "event.h"
 #include "StoreClient.h"
 #include "Store.h"
@@ -194,7 +194,7 @@
     if (getType() == STORE_DISK_CLIENT)
         /* assert we'll be able to get the data we want */
         /* maybe we should open swapin_sio here */
-        assert(entry->swap_filen > -1 || entry->swapOutAble());
+        assert(entry->swap_filen > -1 || entry->swappingOut());
 
 #if STORE_CLIENT_LIST_DEBUG
 
diff -u -r -N squid-3.2.0.14/src/store_digest.cc squid-3.2.0.15/src/store_digest.cc
--- squid-3.2.0.14/src/store_digest.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/store_digest.cc	2012-02-06 04:52:31.000000000 +1300
@@ -40,7 +40,7 @@
  *       storeDigestRebuild/write schedule to be activated
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "event.h"
 #include "mgr/Registration.h"
 #if USE_CACHE_DIGESTS
diff -u -r -N squid-3.2.0.14/src/store_dir.cc squid-3.2.0.15/src/store_dir.cc
--- squid-3.2.0.14/src/store_dir.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/store_dir.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "Store.h"
 #include "MemObject.h"
 #include "MemStore.h"
diff -u -r -N squid-3.2.0.14/src/StoreEntryStream.h squid-3.2.0.15/src/StoreEntryStream.h
--- squid-3.2.0.14/src/StoreEntryStream.h	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/StoreEntryStream.h	2012-02-06 04:52:31.000000000 +1300
@@ -70,7 +70,10 @@
             return traits_type::eof();
 
         if (aChar != traits_type::eof()) {
-            char chars[1] = {aChar};
+            // NP: cast because GCC promotes int_type to 32-bit type
+            //     std::basic_streambuf<char>::int_type {aka int}
+            //     despite the definition with 8-bit type value.
+            char chars[1] = {char(aChar)};
 
             if (aChar != traits_type::eof())
                 theEntry->append(chars, 1);
diff -u -r -N squid-3.2.0.14/src/StoreFileSystem.cc squid-3.2.0.15/src/StoreFileSystem.cc
--- squid-3.2.0.14/src/StoreFileSystem.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/StoreFileSystem.cc	2012-02-06 04:52:31.000000000 +1300
@@ -34,7 +34,7 @@
  * Copyright (c) 2003, Robert Collins <robertc@squid-cache.org>
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "StoreFileSystem.h"
 
 Vector<StoreFileSystem*> *StoreFileSystem::_FileSystems = NULL;
diff -u -r -N squid-3.2.0.14/src/StoreFileSystem.h squid-3.2.0.15/src/StoreFileSystem.h
--- squid-3.2.0.14/src/StoreFileSystem.h	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/StoreFileSystem.h	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
 #ifndef SQUID_STOREFILESYSTEM_H
 #define SQUID_STOREFILESYSTEM_H
 
-#include "squid.h"
+#include "squid-old.h"
 #include "Array.h"
 
 /* ****** DOCUMENTATION ***** */
diff -u -r -N squid-3.2.0.14/src/Store.h squid-3.2.0.15/src/Store.h
--- squid-3.2.0.14/src/Store.h	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/Store.h	2012-02-06 04:52:31.000000000 +1300
@@ -37,7 +37,7 @@
  \ingroup FileSystems
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "StoreIOBuffer.h"
 #include "Range.h"
 #include "RefCount.h"
@@ -92,8 +92,9 @@
     virtual char const *getSerialisedMetaData();
     void replaceHttpReply(HttpReply *, bool andStartWriting = true);
     void startWriting(); ///< pack and write reply headers and, maybe, body
-    virtual bool swapoutPossible();
-    virtual void trimMemory();
+    /// whether we may start writing to disk (now or in the future)
+    virtual bool mayStartSwapOut();
+    virtual void trimMemory(const bool preserveSwappable);
     void abort();
     void unlink();
     void makePublic();
@@ -108,7 +109,8 @@
     void purgeMem();
     void cacheInMemory(); ///< start or continue storing in memory cache
     void swapOut();
-    bool swapOutAble() const;
+    /// whether we are in the process of writing this entry to disk
+    bool swappingOut() const { return swap_status == SWAPOUT_WRITING; }
     void swapOutFileClose(int how);
     const char *url() const;
     int checkCachable();
@@ -247,9 +249,9 @@
     store_client_t storeClientType() const {return STORE_MEM_CLIENT;}
 
     char const *getSerialisedMetaData();
-    bool swapoutPossible() {return false;}
+    bool mayStartSwapout() {return false;}
 
-    void trimMemory() {}
+    void trimMemory(const bool preserveSwappable) {}
 
 
     static NullStoreEntry _instance;
diff -u -r -N squid-3.2.0.14/src/store_io.cc squid-3.2.0.15/src/store_io.cc
--- squid-3.2.0.14/src/store_io.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/store_io.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "squid.h"
+#include "squid-old.h"
 #include "Store.h"
 #include "MemObject.h"
 #include "SwapDir.h"
diff -u -r -N squid-3.2.0.14/src/StoreIOState.cc squid-3.2.0.15/src/StoreIOState.cc
--- squid-3.2.0.14/src/StoreIOState.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/StoreIOState.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "StoreIOState.h"
 
 void *
diff -u -r -N squid-3.2.0.14/src/store_key_md5.cc squid-3.2.0.15/src/store_key_md5.cc
--- squid-3.2.0.14/src/store_key_md5.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/store_key_md5.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "HttpRequest.h"
 
 static cache_key null_key[SQUID_MD5_DIGEST_LENGTH];
diff -u -r -N squid-3.2.0.14/src/store_log.cc squid-3.2.0.15/src/store_log.cc
--- squid-3.2.0.14/src/store_log.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/store_log.cc	2012-02-06 04:52:31.000000000 +1300
@@ -32,7 +32,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "format/Token.h"
 #include "HttpReply.h"
 #include "log/File.h"
diff -u -r -N squid-3.2.0.14/src/StoreMeta.cc squid-3.2.0.15/src/StoreMeta.cc
--- squid-3.2.0.14/src/StoreMeta.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/StoreMeta.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "StoreMeta.h"
 #include "Store.h"
 #include "MemObject.h"
diff -u -r -N squid-3.2.0.14/src/StoreMetaMD5.cc squid-3.2.0.15/src/StoreMetaMD5.cc
--- squid-3.2.0.14/src/StoreMetaMD5.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/StoreMetaMD5.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "StoreMetaMD5.h"
 #include "Store.h"
 #include "MemObject.h"
diff -u -r -N squid-3.2.0.14/src/StoreMetaSTD.cc squid-3.2.0.15/src/StoreMetaSTD.cc
--- squid-3.2.0.14/src/StoreMetaSTD.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/StoreMetaSTD.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "StoreMetaSTD.h"
 #include "Store.h"
 #include "MemObject.h"
diff -u -r -N squid-3.2.0.14/src/StoreMetaSTDLFS.cc squid-3.2.0.15/src/StoreMetaSTDLFS.cc
--- squid-3.2.0.14/src/StoreMetaSTDLFS.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/StoreMetaSTDLFS.cc	2012-02-06 04:52:31.000000000 +1300
@@ -32,7 +32,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "StoreMetaSTDLFS.h"
 #include "Store.h"
 #include "MemObject.h"
diff -u -r -N squid-3.2.0.14/src/StoreMetaUnpacker.cc squid-3.2.0.15/src/StoreMetaUnpacker.cc
--- squid-3.2.0.14/src/StoreMetaUnpacker.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/StoreMetaUnpacker.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "StoreMetaUnpacker.h"
 #include "StoreMeta.h"
 
diff -u -r -N squid-3.2.0.14/src/StoreMetaURL.cc squid-3.2.0.15/src/StoreMetaURL.cc
--- squid-3.2.0.14/src/StoreMetaURL.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/StoreMetaURL.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "StoreMetaURL.h"
 #include "Store.h"
 #include "MemObject.h"
diff -u -r -N squid-3.2.0.14/src/StoreMetaVary.cc squid-3.2.0.15/src/StoreMetaVary.cc
--- squid-3.2.0.14/src/StoreMetaVary.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/StoreMetaVary.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "StoreMetaVary.h"
 #include "Store.h"
 #include "MemObject.h"
diff -u -r -N squid-3.2.0.14/src/store_rebuild.cc squid-3.2.0.15/src/store_rebuild.cc
--- squid-3.2.0.14/src/store_rebuild.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/store_rebuild.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "event.h"
 #include "Store.h"
 #include "SwapDir.h"
diff -u -r -N squid-3.2.0.14/src/StoreSearch.h squid-3.2.0.15/src/StoreSearch.h
--- squid-3.2.0.14/src/StoreSearch.h	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/StoreSearch.h	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
 #ifndef SQUID_STORESEARCH_H
 #define SQUID_STORESEARCH_H
 
-#include "squid.h"
+#include "squid-old.h"
 #include "RefCount.h"
 #include "Store.h"
 
diff -u -r -N squid-3.2.0.14/src/StoreStats.cc squid-3.2.0.15/src/StoreStats.cc
--- squid-3.2.0.14/src/StoreStats.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/StoreStats.cc	2012-02-06 04:52:31.000000000 +1300
@@ -5,7 +5,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 #include "protos.h" /* for xmemset only */
 #include "StoreStats.h"
 
diff -u -r -N squid-3.2.0.14/src/store_swapin.cc squid-3.2.0.15/src/store_swapin.cc
--- squid-3.2.0.14/src/store_swapin.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/store_swapin.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "StoreClient.h"
 #include "Store.h"
 
diff -u -r -N squid-3.2.0.14/src/StoreSwapLogData.cc squid-3.2.0.15/src/StoreSwapLogData.cc
--- squid-3.2.0.14/src/StoreSwapLogData.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/StoreSwapLogData.cc	2012-02-06 04:52:31.000000000 +1300
@@ -32,7 +32,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 #include "StoreSwapLogData.h"
 #include "swap_log_op.h"
 
@@ -41,6 +41,24 @@
     memset (key, '\0', sizeof(key));
 }
 
+bool
+StoreSwapLogData::sane() const
+{
+    // TODO: These checks are rather weak. A corrupted swap.state may still
+    // cause havoc (e.g., cur_size may become astronomical). Add checksums?
+
+    const time_t minTime = -2; // -1 is common; expires sometimes uses -2
+
+    // Check what we safely can; for some fields any value might be valid
+    return SWAP_LOG_NOP < op && op < SWAP_LOG_MAX &&
+           swap_filen >= 0 &&
+           timestamp >= minTime &&
+           lastref >= minTime &&
+           expires >= minTime &&
+           lastmod >= minTime &&
+           swap_file_sz > 0; // because swap headers ought to consume space
+}
+
 StoreSwapLogHeader::StoreSwapLogHeader():op(SWAP_LOG_VERSION), version(1)
 {
     record_size = sizeof(StoreSwapLogData);
diff -u -r -N squid-3.2.0.14/src/StoreSwapLogData.h squid-3.2.0.15/src/StoreSwapLogData.h
--- squid-3.2.0.14/src/StoreSwapLogData.h	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/StoreSwapLogData.h	2012-02-06 04:52:31.000000000 +1300
@@ -59,7 +59,7 @@
  *      the value for MemObject->swap_hdr_sz.
  */
 
-#include "squid.h"
+#include "squid-old.h"
 
 /*
  * Do we need to have the dirn in here? I don't think so, since we already
@@ -86,6 +86,9 @@
     MEMPROXY_CLASS(StoreSwapLogData);
     StoreSwapLogData();
 
+    /// consistency self-check: whether the data appears to make sense
+    bool sane() const;
+
     /**
      * Either SWAP_LOG_ADD when an object is added to the disk storage,
      * or SWAP_LOG_DEL when an object is deleted.
diff -u -r -N squid-3.2.0.14/src/store_swapmeta.cc squid-3.2.0.15/src/store_swapmeta.cc
--- squid-3.2.0.14/src/store_swapmeta.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/store_swapmeta.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "Store.h"
 #include "MemObject.h"
 #include "StoreMeta.h"
diff -u -r -N squid-3.2.0.14/src/store_swapout.cc squid-3.2.0.15/src/store_swapout.cc
--- squid-3.2.0.14/src/store_swapout.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/store_swapout.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "cbdata.h"
 #include "StoreClient.h"
 #include "Store.h"
@@ -187,8 +187,20 @@
     if (!mem_obj)
         return;
 
-    if (!swapoutPossible())
+    // this flag may change so we must check even if we are swappingOut
+    if (EBIT_TEST(flags, ENTRY_ABORTED)) {
+        assert(EBIT_TEST(flags, RELEASE_REQUEST));
+        // StoreEntry::abort() already closed the swap out file, if any
+        // no trimming: data producer must stop production if ENTRY_ABORTED
         return;
+    }
+
+    const bool weAreOrMayBeSwappingOut = swappingOut() || mayStartSwapOut();
+
+    trimMemory(weAreOrMayBeSwappingOut);
+
+    if (!weAreOrMayBeSwappingOut)
+        return; // nothing else to do
 
     // Aborted entries have STORE_OK, but swapoutPossible rejects them. Thus,
     // store_status == STORE_OK below means we got everything we wanted.
@@ -200,39 +212,10 @@
     if (mem_obj->swapout.sio != NULL)
         debugs(20, 7, "storeSwapOut: storeOffset() = " << mem_obj->swapout.sio->offset()  );
 
-    // buffered bytes we have not swapped out yet
-    int64_t swapout_maxsize = mem_obj->endOffset() - mem_obj->swapout.queue_offset;
-
-    assert(swapout_maxsize >= 0);
-
     int64_t const lowest_offset = mem_obj->lowestMemReaderOffset();
 
     debugs(20, 7, HERE << "storeSwapOut: lowest_offset = " << lowest_offset);
 
-    // Check to see whether we're going to defer the swapout based upon size
-    if (store_status != STORE_OK) {
-        const int64_t expectedSize = mem_obj->expectedReplySize();
-        const int64_t maxKnownSize = expectedSize < 0 ?
-                                     swapout_maxsize : expectedSize;
-        debugs(20, 7, HERE << "storeSwapOut: maxKnownSize= " << maxKnownSize);
-
-        if (maxKnownSize < store_maxobjsize) {
-            /*
-             * NOTE: the store_maxobjsize here is the max of optional
-             * max-size values from 'cache_dir' lines.  It is not the
-             * same as 'maximum_object_size'.  By default, store_maxobjsize
-             * will be set to -1.  However, I am worried that this
-             * deferance may consume a lot of memory in some cases.
-             * Should we add an option to limit this memory consumption?
-             */
-            debugs(20, 5, "storeSwapOut: Deferring swapout start for " <<
-                   (store_maxobjsize - maxKnownSize) << " bytes");
-            return;
-        }
-    }
-
-// TODO: it is better to trim as soon as we swap something out, not before
-    trimMemory();
 #if SIZEOF_OFF_T <= 4
 
     if (mem_obj->endOffset() > 0x7FFF0000) {
@@ -245,9 +228,9 @@
     if (swap_status == SWAPOUT_WRITING)
         assert(mem_obj->inmem_lo <=  mem_obj->objectBytesOnDisk() );
 
-    if (!swapOutAble())
-        return;
-
+    // buffered bytes we have not swapped out yet
+    const int64_t swapout_maxsize = mem_obj->availableForSwapOut();
+    assert(swapout_maxsize >= 0);
     debugs(20, 7, "storeSwapOut: swapout_size = " << swapout_maxsize);
 
     if (swapout_maxsize == 0) { // swapped everything we got
@@ -373,19 +356,106 @@
     e->unlock();
 }
 
-/*
- * Is this entry a candidate for writing to disk?
- */
 bool
-StoreEntry::swapOutAble() const
+StoreEntry::mayStartSwapOut()
 {
     dlink_node *node;
 
-    if (mem_obj->swapout.sio != NULL)
+    // must be checked in the caller
+    assert(!EBIT_TEST(flags, ENTRY_ABORTED));
+
+    if (!Config.cacheSwap.n_configured)
+        return false;
+
+    assert(mem_obj);
+    MemObject::SwapOut::Decision &decision = mem_obj->swapout.decision;
+
+    // if we decided that swapout is not possible, do not repeat same checks
+    if (decision == MemObject::SwapOut::swImpossible) {
+        debugs(20, 3, HERE << " already rejected");
+        return false;
+    }
+
+    // if we decided that swapout is possible, do not repeat same checks
+    if (decision == MemObject::SwapOut::swPossible) {
+        debugs(20, 3,  HERE << "already allowed");
         return true;
+    }
+
+    // if we are swapping out already, do not repeat same checks
+    if (swap_status != SWAPOUT_NONE) {
+        debugs(20, 3,  HERE << " already started");
+        decision = MemObject::SwapOut::swPossible;
+        return true;
+    }
+
+    if (!checkCachable()) {
+        debugs(20, 3,  HERE << "not cachable");
+        decision = MemObject::SwapOut::swImpossible;
+        return false;
+    }
+
+    if (EBIT_TEST(flags, ENTRY_SPECIAL)) {
+        debugs(20, 3,  HERE  << url() << " SPECIAL");
+        decision = MemObject::SwapOut::swImpossible;
+        return false;
+    }
+
+    // check cache_dir max-size limit if all cache_dirs have it
+    if (store_maxobjsize >= 0) {
+        // TODO: add estimated store metadata size to be conservative
+
+        // use guaranteed maximum if it is known
+        const int64_t expectedEnd = mem_obj->expectedReplySize();
+        debugs(20, 7,  HERE << "expectedEnd = " << expectedEnd);
+        if (expectedEnd > store_maxobjsize) {
+            debugs(20, 3,  HERE << "will not fit: " << expectedEnd <<
+                   " > " << store_maxobjsize);
+            decision = MemObject::SwapOut::swImpossible;
+            return false; // known to outgrow the limit eventually
+        }
+
+        // use current minimum (always known)
+        const int64_t currentEnd = mem_obj->endOffset();
+        if (currentEnd > store_maxobjsize) {
+            debugs(20, 3,  HERE << "does not fit: " << currentEnd <<
+                   " > " << store_maxobjsize);
+            decision = MemObject::SwapOut::swImpossible;
+            return false; // already does not fit and may only get bigger
+        }
+
+        // prevent default swPossible answer for yet unknown length
+        if (expectedEnd < 0) {
+            debugs(20, 3,  HERE << "wait for more info: " <<
+                   store_maxobjsize);
+            return false; // may fit later, but will be rejected now
+        }
 
-    if (mem_obj->inmem_lo > 0)
+        if (store_status != STORE_OK) {
+            const int64_t maxKnownSize = expectedEnd < 0 ?
+                                         mem_obj->availableForSwapOut() : expectedEnd;
+            debugs(20, 7, HERE << "maxKnownSize= " << maxKnownSize);
+            if (maxKnownSize < store_maxobjsize) {
+                /*
+                 * NOTE: the store_maxobjsize here is the max of optional
+                 * max-size values from 'cache_dir' lines.  It is not the
+                 * same as 'maximum_object_size'.  By default, store_maxobjsize
+                 * will be set to -1.  However, I am worried that this
+                 * deferance may consume a lot of memory in some cases.
+                 * Should we add an option to limit this memory consumption?
+                 */
+                debugs(20, 5,  HERE << "Deferring swapout start for " <<
+                       (store_maxobjsize - maxKnownSize) << " bytes");
+                return false;
+            }
+        }
+    }
+
+    if (mem_obj->inmem_lo > 0) {
+        debugs(20, 3, "storeSwapOut: (inmem_lo > 0)  imem_lo:" <<  mem_obj->inmem_lo);
+        decision = MemObject::SwapOut::swImpossible;
         return false;
+    }
 
     /*
      * If there are DISK clients, we must write to disk
@@ -394,21 +464,29 @@
      * therefore this should be an assert?
      * RBC 20030708: We can use disk to avoid mem races, so this shouldn't be
      * an assert.
+     *
+     * XXX: Not clear what "mem races" the above refers to, especially when
+     * dealing with non-cachable objects that cannot have multiple clients.
+     *
+     * XXX: If STORE_DISK_CLIENT needs SwapOut::swPossible, we have to check
+     * for that flag earlier, but forcing swapping may contradict max-size or
+     * other swapability restrictions. Change storeClientType() and/or its
+     * callers to take swap-in availability into account.
      */
     for (node = mem_obj->clients.head; node; node = node->next) {
-        if (((store_client *) node->data)->getType() == STORE_DISK_CLIENT)
+        if (((store_client *) node->data)->getType() == STORE_DISK_CLIENT) {
+            debugs(20, 3, HERE << "DISK client found");
+            decision = MemObject::SwapOut::swPossible;
             return true;
+        }
     }
 
-    /* Don't pollute the disk with icons and other special entries */
-    if (EBIT_TEST(flags, ENTRY_SPECIAL))
-        return false;
-
-    if (!EBIT_TEST(flags, ENTRY_CACHABLE))
-        return false;
-
-    if (!mem_obj->isContiguous())
+    if (!mem_obj->isContiguous()) {
+        debugs(20, 3, "storeSwapOut: not Contiguous");
+        decision = MemObject::SwapOut::swImpossible;
         return false;
+    }
 
+    decision = MemObject::SwapOut::swPossible;
     return true;
 }
diff -u -r -N squid-3.2.0.14/src/String.cc squid-3.2.0.15/src/String.cc
--- squid-3.2.0.14/src/String.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/String.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "base/TextException.h"
 #include "mgr/Registration.h"
 #include "Store.h"
diff -u -r -N squid-3.2.0.14/src/structs.h squid-3.2.0.15/src/structs.h
--- squid-3.2.0.14/src/structs.h	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/structs.h	2012-02-06 04:52:31.000000000 +1300
@@ -144,6 +144,8 @@
 class CpuAffinityMap;
 class RemovalPolicySettings;
 class external_acl;
+class Store;
+struct http_port_list;
 class SwapDir;
 
 /// Used for boolean enabled/disabled options with complex default logic.
@@ -216,8 +218,7 @@
         int icp_query_min;	/* msec */
         int mcast_icp_query;	/* msec */
 
-#if !USE_DNSSERVERS
-
+#if !USE_DNSHELPER
         time_msec_t idns_retransmit;
         time_msec_t idns_query;
 #endif
@@ -245,8 +246,7 @@
     struct {
         http_port_list *http;
 #if USE_SSL
-
-        https_port_list *https;
+        http_port_list *https;
 #endif
 
     } Sockaddr;
@@ -302,7 +302,7 @@
     char *effectiveGroup;
 
     struct {
-#if USE_DNSSERVERS
+#if USE_DNSHELPER
         char *dnsserver;
 #endif
 
@@ -319,8 +319,7 @@
 #endif
 
     } Program;
-#if USE_DNSSERVERS
-
+#if USE_DNSHELPER
     HelperChildConfig dnsChildren;
 #endif
 
@@ -446,7 +445,6 @@
         int emailErrData;
         int httpd_suppress_version_string;
         int global_internal_static;
-        int dns_require_A;
 
 #if FOLLOW_X_FORWARDED_FOR
         int acl_uses_indirect_client;
@@ -980,7 +978,9 @@
 
 
 struct request_flags {
-    request_flags(): range(0),nocache(0),ims(0),auth(0),cachable(0),hierarchical(0),loopdetect(0),proxy_keepalive(0),proxying(0),refresh(0),redirected(0),need_validation(0),fail_on_validation_err(0),stale_if_hit(0),accelerated(0),ignore_cc(0),intercepted(0),spoof_client_ip(0),internal(0),internalclient(0),must_keepalive(0),chunked_reply(0),stream_error(0),sslBumped(0),destinationIPLookedUp_(0) {
+    request_flags(): range(0),nocache(0),ims(0),auth(0),cachable(0),hierarchical(0),loopdetect(0),proxy_keepalive(0),proxying(0),refresh(0),redirected(0),need_validation(0),fail_on_validation_err(0),stale_if_hit(0),accelerated(0),ignore_cc(0),intercepted(0),
+            hostVerified(0),
+            spoof_client_ip(0),internal(0),internalclient(0),must_keepalive(0),chunked_reply(0),stream_error(0),sslBumped(0),destinationIPLookedUp_(0) {
 #if USE_HTTP_VIOLATIONS
         nocache_hack = 0;
 #endif
@@ -990,10 +990,10 @@
     }
 
     unsigned int range:1;
-    unsigned int nocache:1;
+    unsigned int nocache:1;            ///< whether the response to this request may be READ from cache
     unsigned int ims:1;
     unsigned int auth:1;
-    unsigned int cachable:1;
+    unsigned int cachable:1;           ///< whether the response to thie request may be stored in the cache
     unsigned int hierarchical:1;
     unsigned int loopdetect:1;
     unsigned int proxy_keepalive:1;
@@ -1009,7 +1009,8 @@
 #endif
     unsigned int accelerated:1;
     unsigned int ignore_cc:1;
-    unsigned int intercepted:1;  /**< transparently intercepted request */
+    unsigned int intercepted:1;        ///< intercepted request
+    unsigned int hostVerified:1;       ///< whether the Host: header passed verification
     unsigned int spoof_client_ip:1;  /**< spoof client ip if possible */
     unsigned int internal:1;
     unsigned int internalclient:1;
diff -u -r -N squid-3.2.0.14/src/SwapDir.cc squid-3.2.0.15/src/SwapDir.cc
--- squid-3.2.0.14/src/SwapDir.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/SwapDir.cc	2012-02-06 04:52:31.000000000 +1300
@@ -32,7 +32,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "compat/strtoll.h"
 #include "SwapDir.h"
 #include "StoreFileSystem.h"
diff -u -r -N squid-3.2.0.14/src/swap_log_op.cc squid-3.2.0.15/src/swap_log_op.cc
--- squid-3.2.0.14/src/swap_log_op.cc	2011-12-13 01:29:11.000000000 +1300
+++ squid-3.2.0.15/src/swap_log_op.cc	2012-02-06 06:02:31.000000000 +1300
@@ -1,7 +1,7 @@
 /*
  * Auto-Generated File. Changes will be destroyed.
  */
-#include "config.h"
+#include "squid.h"
 #include "swap_log_op.h"
 
 const char *swap_log_op_str[] = {
diff -u -r -N squid-3.2.0.14/src/tests/stub_access_log.cc squid-3.2.0.15/src/tests/stub_access_log.cc
--- squid-3.2.0.14/src/tests/stub_access_log.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/tests/stub_access_log.cc	2012-02-06 04:52:31.000000000 +1300
@@ -32,7 +32,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "HierarchyLogEntry.h"
 
 
diff -u -r -N squid-3.2.0.14/src/tests/stub_acl.cc squid-3.2.0.15/src/tests/stub_acl.cc
--- squid-3.2.0.14/src/tests/stub_acl.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/tests/stub_acl.cc	2012-02-06 04:52:31.000000000 +1300
@@ -32,7 +32,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 
 /*
  * DO NOT MODIFY:
diff -u -r -N squid-3.2.0.14/src/tests/stub_cache_cf.cc squid-3.2.0.15/src/tests/stub_cache_cf.cc
--- squid-3.2.0.14/src/tests/stub_cache_cf.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/tests/stub_cache_cf.cc	2012-02-06 04:52:31.000000000 +1300
@@ -32,7 +32,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "ConfigParser.h"
 #include "wordlist.h"
 
diff -u -r -N squid-3.2.0.14/src/tests/stub_cache_manager.cc squid-3.2.0.15/src/tests/stub_cache_manager.cc
--- squid-3.2.0.14/src/tests/stub_cache_manager.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/tests/stub_cache_manager.cc	2012-02-06 04:52:31.000000000 +1300
@@ -29,7 +29,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "CacheManager.h"
 #include "mgr/Registration.h"
 
diff -u -r -N squid-3.2.0.14/src/tests/stub_client_db.cc squid-3.2.0.15/src/tests/stub_client_db.cc
--- squid-3.2.0.14/src/tests/stub_client_db.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/tests/stub_client_db.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "config.h"
+#include "squid.h"
 /* because the clientdb API is defined in protos.h still */
 #include "protos.h"
 
diff -u -r -N squid-3.2.0.14/src/tests/stub_client_side_request.cc squid-3.2.0.15/src/tests/stub_client_side_request.cc
--- squid-3.2.0.14/src/tests/stub_client_side_request.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/tests/stub_client_side_request.cc	2012-02-06 04:52:31.000000000 +1300
@@ -31,7 +31,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 #include "client_side_request.h"
 #include "Store.h"
 
diff -u -r -N squid-3.2.0.14/src/tests/stub_comm.cc squid-3.2.0.15/src/tests/stub_comm.cc
--- squid-3.2.0.14/src/tests/stub_comm.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/tests/stub_comm.cc	2012-02-06 04:52:31.000000000 +1300
@@ -112,11 +112,10 @@
     return -1;
 }
 
-int
-commSetTimeout(int fd, int timeout, PF * handler, void *data)
+void
+commUnsetFdTimeout(int fd)
 {
     fatal ("Not implemented");
-    return -1;
 }
 
 int
diff -u -r -N squid-3.2.0.14/src/tests/stub_CommIO.cc squid-3.2.0.15/src/tests/stub_CommIO.cc
--- squid-3.2.0.14/src/tests/stub_CommIO.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/tests/stub_CommIO.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "squid.h"
+#include "squid-old.h"
 #include "CommIO.h"
 
 bool CommIO::Initialised = false;
diff -u -r -N squid-3.2.0.14/src/tests/stub_debug.cc squid-3.2.0.15/src/tests/stub_debug.cc
--- squid-3.2.0.14/src/tests/stub_debug.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/tests/stub_debug.cc	2012-02-06 04:52:31.000000000 +1300
@@ -2,7 +2,7 @@
  * A stub implementation of the Debug.h API.
  * For use by test binaries which do not need the full context debugging
  */
-#include "config.h"
+#include "squid.h"
 #include "Debug.h"
 
 #if HAVE_STDIO_H
diff -u -r -N squid-3.2.0.14/src/tests/stub_DelayId.cc squid-3.2.0.15/src/tests/stub_DelayId.cc
--- squid-3.2.0.14/src/tests/stub_DelayId.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/tests/stub_DelayId.cc	2012-02-06 04:52:31.000000000 +1300
@@ -32,10 +32,10 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 
 #if USE_DELAY_POOLS
-#include "squid.h"
+#include "squid-old.h"
 #include "DelayId.h"
 
 DelayId::DelayId() {}
diff -u -r -N squid-3.2.0.14/src/tests/stub_DiskIOModule.cc squid-3.2.0.15/src/tests/stub_DiskIOModule.cc
--- squid-3.2.0.14/src/tests/stub_DiskIOModule.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/tests/stub_DiskIOModule.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "config.h"
+#include "squid.h"
 
 #define STUB_API "DiskIOModule.cc"
 #include "tests/STUB.h"
diff -u -r -N squid-3.2.0.14/src/tests/stub_errorpage.cc squid-3.2.0.15/src/tests/stub_errorpage.cc
--- squid-3.2.0.14/src/tests/stub_errorpage.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/tests/stub_errorpage.cc	2012-02-06 04:52:31.000000000 +1300
@@ -32,7 +32,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 #include "errorpage.h"
 
 err_type
@@ -62,7 +62,7 @@
     return false;
 }
 
-TemplateFile::TemplateFile(char const*)
+TemplateFile::TemplateFile(char const*, err_type)
 {
     fatal("Not implemented");
 }
diff -u -r -N squid-3.2.0.14/src/tests/stub_event.cc squid-3.2.0.15/src/tests/stub_event.cc
--- squid-3.2.0.14/src/tests/stub_event.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/tests/stub_event.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "config.h"
+#include "squid.h"
 #include "event.h"
 
 #define STUB_API "event.cc"
diff -u -r -N squid-3.2.0.14/src/tests/stub_fd.cc squid-3.2.0.15/src/tests/stub_fd.cc
--- squid-3.2.0.14/src/tests/stub_fd.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/tests/stub_fd.cc	2012-02-06 04:52:31.000000000 +1300
@@ -32,7 +32,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 #include "fde.h"
 
 int
diff -u -r -N squid-3.2.0.14/src/tests/stub_HelperChildConfig.cc squid-3.2.0.15/src/tests/stub_HelperChildConfig.cc
--- squid-3.2.0.14/src/tests/stub_HelperChildConfig.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/tests/stub_HelperChildConfig.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "config.h"
+#include "squid.h"
 #include "HelperChildConfig.h"
 #include "globals.h"
 
diff -u -r -N squid-3.2.0.14/src/tests/stub_http.cc squid-3.2.0.15/src/tests/stub_http.cc
--- squid-3.2.0.14/src/tests/stub_http.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/tests/stub_http.cc	2012-02-06 04:52:31.000000000 +1300
@@ -32,7 +32,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 
 const char *
 httpMakeVaryMark(HttpRequest * request, HttpReply const * reply)
diff -u -r -N squid-3.2.0.14/src/tests/stub_icp.cc squid-3.2.0.15/src/tests/stub_icp.cc
--- squid-3.2.0.14/src/tests/stub_icp.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/tests/stub_icp.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "config.h"
+#include "squid.h"
 #include "comm/Connection.h"
 #include "ICP.h"
 #include "icp_opcode.h"
diff -u -r -N squid-3.2.0.14/src/tests/stub_internal.cc squid-3.2.0.15/src/tests/stub_internal.cc
--- squid-3.2.0.14/src/tests/stub_internal.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/tests/stub_internal.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,6 +33,7 @@
  */
 
 #include "squid.h"
+#include "fatal.h"
 
 char *
 internalLocalUri(const char *dir, const char *name)
diff -u -r -N squid-3.2.0.14/src/tests/stub_ipcache.cc squid-3.2.0.15/src/tests/stub_ipcache.cc
--- squid-3.2.0.14/src/tests/stub_ipcache.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/tests/stub_ipcache.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "config.h"
+#include "squid.h"
 #include "ipcache.h"
 
 #define STUB_API "ipcache.cc"
diff -u -r -N squid-3.2.0.14/src/tests/stub_ipc.cc squid-3.2.0.15/src/tests/stub_ipc.cc
--- squid-3.2.0.14/src/tests/stub_ipc.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/tests/stub_ipc.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "config.h"
+#include "squid.h"
 // because ipcCreate is defined in protos.h still
 #include "protos.h"
 
diff -u -r -N squid-3.2.0.14/src/tests/stub_ipc_Forwarder.cc squid-3.2.0.15/src/tests/stub_ipc_Forwarder.cc
--- squid-3.2.0.14/src/tests/stub_ipc_Forwarder.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/tests/stub_ipc_Forwarder.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "config.h"
+#include "squid.h"
 #include "ipc/Forwarder.h"
 
 //Avoid linker errors about Ipc::Forwarder
diff -u -r -N squid-3.2.0.14/src/tests/stub_libcomm.cc squid-3.2.0.15/src/tests/stub_libcomm.cc
--- squid-3.2.0.14/src/tests/stub_libcomm.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/tests/stub_libcomm.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "config.h"
+#include "squid.h"
 #include "base/AsyncJob.h"
 #include "structs.h"
 
diff -u -r -N squid-3.2.0.14/src/tests/stub_libicmp.cc squid-3.2.0.15/src/tests/stub_libicmp.cc
--- squid-3.2.0.14/src/tests/stub_libicmp.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/tests/stub_libicmp.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "config.h"
+#include "squid.h"
 #define STUB_API "icmp/libicmp.la"
 #include "STUB.h"
 
diff -u -r -N squid-3.2.0.14/src/tests/stub_main_cc.cc squid-3.2.0.15/src/tests/stub_main_cc.cc
--- squid-3.2.0.14/src/tests/stub_main_cc.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/tests/stub_main_cc.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 
 void
 shut_down(int)
diff -u -r -N squid-3.2.0.14/src/tests/stub_MemObject.cc squid-3.2.0.15/src/tests/stub_MemObject.cc
--- squid-3.2.0.14/src/tests/stub_MemObject.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/tests/stub_MemObject.cc	2012-02-06 04:52:31.000000000 +1300
@@ -206,3 +206,10 @@
     fatal ("MemObject.cc required.");
     return 0;
 }
+
+int64_t
+MemObject::availableForSwapOut() const
+{
+    fatal ("MemObject.cc required.");
+    return 0;
+}
diff -u -r -N squid-3.2.0.14/src/tests/stub_MemStore.cc squid-3.2.0.15/src/tests/stub_MemStore.cc
--- squid-3.2.0.14/src/tests/stub_MemStore.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/tests/stub_MemStore.cc	2012-02-06 04:52:31.000000000 +1300
@@ -5,7 +5,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 #include "MemStore.h"
 
 #define STUB_API "MemStore.cc"
diff -u -r -N squid-3.2.0.14/src/tests/stub_mime.cc squid-3.2.0.15/src/tests/stub_mime.cc
--- squid-3.2.0.14/src/tests/stub_mime.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/tests/stub_mime.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,6 +33,8 @@
  */
 
 #include "squid.h"
+#include "fatal.h"
+#include "protos.h"
 
 size_t
 headersEnd(const char *mime, size_t l)
diff -u -r -N squid-3.2.0.14/src/tests/stub_pconn.cc squid-3.2.0.15/src/tests/stub_pconn.cc
--- squid-3.2.0.14/src/tests/stub_pconn.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/tests/stub_pconn.cc	2012-02-06 04:52:31.000000000 +1300
@@ -2,7 +2,7 @@
  * STUB file for the pconn.cc API
  * Functions here are inactive.
  */
-#include "config.h"
+#include "squid.h"
 #include "pconn.h"
 #include "comm/Connection.h"
 
diff -u -r -N squid-3.2.0.14/src/tests/stub_Port.cc squid-3.2.0.15/src/tests/stub_Port.cc
--- squid-3.2.0.14/src/tests/stub_Port.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/tests/stub_Port.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "config.h"
+#include "squid.h"
 #include "ipc/Port.h"
 
 #define STUB_API "ipc/Port.cc"
diff -u -r -N squid-3.2.0.14/src/tests/stub_store.cc squid-3.2.0.15/src/tests/stub_store.cc
--- squid-3.2.0.14/src/tests/stub_store.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/tests/stub_store.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "squid.h"
+#include "squid-old.h"
 
 #define STUB_API "store.cc"
 #include "tests/STUB.h"
@@ -26,8 +26,8 @@
 store_client_t StoreEntry::storeClientType() const STUB_RETVAL(STORE_NON_CLIENT)
 char const *StoreEntry::getSerialisedMetaData() STUB_RETVAL(NULL)
 void StoreEntry::replaceHttpReply(HttpReply *, bool andStartWriting) STUB
-bool StoreEntry::swapoutPossible() STUB_RETVAL(false)
-void StoreEntry::trimMemory() STUB
+bool StoreEntry::mayStartSwapOut() STUB_RETVAL(false)
+void StoreEntry::trimMemory(const bool preserveSwappable) STUB
 void StoreEntry::abort() STUB
 void StoreEntry::unlink() STUB
 void StoreEntry::makePublic() STUB
@@ -41,7 +41,6 @@
 void StoreEntry::invokeHandlers() STUB
 void StoreEntry::purgeMem() STUB
 void StoreEntry::swapOut() STUB
-bool StoreEntry::swapOutAble() const STUB_RETVAL(false)
 void StoreEntry::swapOutFileClose(int how) STUB
 const char *StoreEntry::url() const STUB_RETVAL(NULL)
 int StoreEntry::checkCachable() STUB_RETVAL(0)
diff -u -r -N squid-3.2.0.14/src/tests/stub_store_client.cc squid-3.2.0.15/src/tests/stub_store_client.cc
--- squid-3.2.0.14/src/tests/stub_store_client.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/tests/stub_store_client.cc	2012-02-06 04:52:31.000000000 +1300
@@ -32,7 +32,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "StoreClient.h"
 #include "Store.h"
 
diff -u -r -N squid-3.2.0.14/src/tests/stub_store_rebuild.cc squid-3.2.0.15/src/tests/stub_store_rebuild.cc
--- squid-3.2.0.14/src/tests/stub_store_rebuild.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/tests/stub_store_rebuild.cc	2012-02-06 04:52:31.000000000 +1300
@@ -32,7 +32,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 
 void
 storeRebuildProgress(int sd_index, int total, int sofar)
diff -u -r -N squid-3.2.0.14/src/tests/stub_store_stats.cc squid-3.2.0.15/src/tests/stub_store_stats.cc
--- squid-3.2.0.14/src/tests/stub_store_stats.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/tests/stub_store_stats.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "squid.h"
+#include "squid-old.h"
 
 #define STUB_API "StoreStats.cc"
 #include "tests/STUB.h"
diff -u -r -N squid-3.2.0.14/src/tests/stub_store_swapout.cc squid-3.2.0.15/src/tests/stub_store_swapout.cc
--- squid-3.2.0.14/src/tests/stub_store_swapout.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/tests/stub_store_swapout.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,13 +33,16 @@
  */
 
 #include "squid.h"
+#include "fatal.h"
 
+#if 0
 /* wrong stub file... */
 void
 storeUnlink(StoreEntry * e)
 {
     fatal ("Not implemented");
 }
+#endif
 
 #include "StoreMeta.h"
 
diff -u -r -N squid-3.2.0.14/src/tests/stub_tools.cc squid-3.2.0.15/src/tests/stub_tools.cc
--- squid-3.2.0.14/src/tests/stub_tools.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/tests/stub_tools.cc	2012-02-06 04:52:31.000000000 +1300
@@ -31,7 +31,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 #include "protos.h"
 
 int
diff -u -r -N squid-3.2.0.14/src/tests/stub_UdsOp.cc squid-3.2.0.15/src/tests/stub_UdsOp.cc
--- squid-3.2.0.14/src/tests/stub_UdsOp.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/tests/stub_UdsOp.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "config.h"
+#include "squid.h"
 #include "ipc/UdsOp.h"
 
 void Ipc::SendMessage(const String& toAddress, const TypedMsgHdr& message)
diff -u -r -N squid-3.2.0.14/src/tests/testACLMaxUserIP.cc squid-3.2.0.15/src/tests/testACLMaxUserIP.cc
--- squid-3.2.0.14/src/tests/testACLMaxUserIP.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/tests/testACLMaxUserIP.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,6 +1,6 @@
 #define SQUID_UNIT_TEST 1
 
-#include "squid.h"
+#include "squid-old.h"
 
 #if USE_AUTH
 
diff -u -r -N squid-3.2.0.14/src/tests/testBoilerplate.cc squid-3.2.0.15/src/tests/testBoilerplate.cc
--- squid-3.2.0.14/src/tests/testBoilerplate.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/tests/testBoilerplate.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,6 +1,6 @@
 #define SQUID_UNIT_TEST 1
 
-#include "squid.h"
+#include "squid-old.h"
 #include "testBoilerplate.h"
 
 #if HAVE_STDEXCEPT
diff -u -r -N squid-3.2.0.14/src/tests/testCacheManager.cc squid-3.2.0.15/src/tests/testCacheManager.cc
--- squid-3.2.0.14/src/tests/testCacheManager.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/tests/testCacheManager.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,6 +1,6 @@
 #define SQUID_UNIT_TEST 1
 
-#include "squid.h"
+#include "squid-old.h"
 #include <cppunit/TestAssert.h>
 #include "mgr/Action.h"
 
diff -u -r -N squid-3.2.0.14/src/tests/testConfigParser.cc squid-3.2.0.15/src/tests/testConfigParser.cc
--- squid-3.2.0.14/src/tests/testConfigParser.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/tests/testConfigParser.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,5 +1,5 @@
 #define SQUID_UNIT_TEST 1
-#include "config.h"
+#include "squid.h"
 
 #include "testConfigParser.h"
 #include "SquidString.h"
diff -u -r -N squid-3.2.0.14/src/tests/testCoss.cc squid-3.2.0.15/src/tests/testCoss.cc
--- squid-3.2.0.14/src/tests/testCoss.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/tests/testCoss.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,5 +1,5 @@
 #define SQUID_UNIT_TEST 1
-#include "squid.h"
+#include "squid-old.h"
 #include "testCoss.h"
 #include "Store.h"
 #include "SwapDir.h"
diff -u -r -N squid-3.2.0.14/src/tests/testDiskIO.cc squid-3.2.0.15/src/tests/testDiskIO.cc
--- squid-3.2.0.14/src/tests/testDiskIO.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/tests/testDiskIO.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,6 +1,6 @@
 #define SQUID_UNIT_TEST 1
 
-#include "squid.h"
+#include "squid-old.h"
 #include "testDiskIO.h"
 #include "Store.h"
 #include "SwapDir.h"
diff -u -r -N squid-3.2.0.14/src/tests/testEvent.cc squid-3.2.0.15/src/tests/testEvent.cc
--- squid-3.2.0.14/src/tests/testEvent.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/tests/testEvent.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,5 +1,5 @@
 #define SQUID_UNIT_TEST 1
-#include "config.h"
+#include "squid.h"
 
 #include <cppunit/TestAssert.h>
 
diff -u -r -N squid-3.2.0.14/src/tests/testEventLoop.cc squid-3.2.0.15/src/tests/testEventLoop.cc
--- squid-3.2.0.14/src/tests/testEventLoop.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/tests/testEventLoop.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,5 +1,5 @@
 #define SQUID_UNIT_TEST 1
-#include "config.h"
+#include "squid.h"
 
 #include <cppunit/TestAssert.h>
 
diff -u -r -N squid-3.2.0.14/src/tests/testHttpParser.cc squid-3.2.0.15/src/tests/testHttpParser.cc
--- squid-3.2.0.14/src/tests/testHttpParser.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/tests/testHttpParser.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,5 +1,5 @@
 #define SQUID_UNIT_TEST 1
-#include "config.h"
+#include "squid.h"
 
 #include <cppunit/TestAssert.h>
 
diff -u -r -N squid-3.2.0.14/src/tests/test_http_range.cc squid-3.2.0.15/src/tests/test_http_range.cc
--- squid-3.2.0.14/src/tests/test_http_range.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/tests/test_http_range.cc	2012-02-06 04:52:31.000000000 +1300
@@ -32,7 +32,7 @@
  *
  */
 #define SQUID_UNIT_TEST 1
-#include "config.h"
+#include "squid.h"
 
 #if 0
 //#include "Store.h"
diff -u -r -N squid-3.2.0.14/src/tests/testHttpReply.cc squid-3.2.0.15/src/tests/testHttpReply.cc
--- squid-3.2.0.14/src/tests/testHttpReply.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/tests/testHttpReply.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,5 +1,5 @@
 #define SQUID_UNIT_TEST 1
-#include "config.h"
+#include "squid.h"
 #include <cppunit/TestAssert.h>
 
 #include "testHttpReply.h"
diff -u -r -N squid-3.2.0.14/src/tests/testHttpRequest.cc squid-3.2.0.15/src/tests/testHttpRequest.cc
--- squid-3.2.0.14/src/tests/testHttpRequest.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/tests/testHttpRequest.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,5 +1,5 @@
 #define SQUID_UNIT_TEST 1
-#include "config.h"
+#include "squid.h"
 
 #include <cppunit/TestAssert.h>
 
diff -u -r -N squid-3.2.0.14/src/tests/testHttpRequestMethod.cc squid-3.2.0.15/src/tests/testHttpRequestMethod.cc
--- squid-3.2.0.14/src/tests/testHttpRequestMethod.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/tests/testHttpRequestMethod.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,6 +1,6 @@
 #define SQUID_UNIT_TEST 1
 
-#include "squid.h"
+#include "squid-old.h"
 #include <cppunit/TestAssert.h>
 
 #include "Mem.h"
diff -u -r -N squid-3.2.0.14/src/tests/testMain.cc squid-3.2.0.15/src/tests/testMain.cc
--- squid-3.2.0.14/src/tests/testMain.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/tests/testMain.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,5 +1,5 @@
 #define SQUID_UNIT_TEST 1
-#include "config.h"
+#include "squid.h"
 
 #include <cppunit/BriefTestProgressListener.h>
 #include <cppunit/TextTestProgressListener.h>
diff -u -r -N squid-3.2.0.14/src/tests/testNull.cc squid-3.2.0.15/src/tests/testNull.cc
--- squid-3.2.0.14/src/tests/testNull.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/tests/testNull.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,5 +1,5 @@
 #define SQUID_UNIT_TEST 1
-#include "squid.h"
+#include "squid-old.h"
 #include "testNull.h"
 #include "Store.h"
 #include "SwapDir.h"
diff -u -r -N squid-3.2.0.14/src/tests/testRock.cc squid-3.2.0.15/src/tests/testRock.cc
--- squid-3.2.0.14/src/tests/testRock.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/tests/testRock.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,5 +1,5 @@
 #define SQUID_UNIT_TEST 1
-#include "config.h"
+#include "squid.h"
 
 #include "DiskIO/DiskIOModule.h"
 #include "HttpHeader.h"
@@ -41,7 +41,7 @@
         throw std::runtime_error("Failed to clean test work directory");
 
     // use current directory for shared segments (on path-based OSes)
-    Ipc::Mem::Segment::BasePath = "";
+    Ipc::Mem::Segment::BasePath = ".";
 
     Store::Root(new StoreController);
 
diff -u -r -N squid-3.2.0.14/src/tests/testStore.cc squid-3.2.0.15/src/tests/testStore.cc
--- squid-3.2.0.14/src/tests/testStore.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/tests/testStore.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,6 +1,6 @@
 #define SQUID_UNIT_TEST 1
 
-#include "squid.h"
+#include "squid-old.h"
 #include "testStore.h"
 #include "Store.h"
 
diff -u -r -N squid-3.2.0.14/src/tests/testStoreController.cc squid-3.2.0.15/src/tests/testStoreController.cc
--- squid-3.2.0.14/src/tests/testStoreController.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/tests/testStoreController.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,6 +1,6 @@
 #define SQUID_UNIT_TEST 1
 
-#include "squid.h"
+#include "squid-old.h"
 
 #include "testStoreController.h"
 #include "Store.h"
diff -u -r -N squid-3.2.0.14/src/tests/testStoreEntryStream.cc squid-3.2.0.15/src/tests/testStoreEntryStream.cc
--- squid-3.2.0.14/src/tests/testStoreEntryStream.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/tests/testStoreEntryStream.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,6 +1,6 @@
 #define SQUID_UNIT_TEST 1
 
-#include "squid.h"
+#include "squid-old.h"
 #include "Mem.h"
 #include "testStore.h"
 #include "testStoreEntryStream.h"
diff -u -r -N squid-3.2.0.14/src/tests/testStore.h squid-3.2.0.15/src/tests/testStore.h
--- squid-3.2.0.14/src/tests/testStore.h	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/tests/testStore.h	2012-02-06 04:52:31.000000000 +1300
@@ -2,7 +2,7 @@
 #ifndef SQUID_SRC_TEST_STORE_H
 #define SQUID_SRC_TEST_STORE_H
 
-#include "squid.h"
+#include "squid-old.h"
 #include "Store.h"
 
 #include <cppunit/extensions/HelperMacros.h>
diff -u -r -N squid-3.2.0.14/src/tests/testStoreHashIndex.cc squid-3.2.0.15/src/tests/testStoreHashIndex.cc
--- squid-3.2.0.14/src/tests/testStoreHashIndex.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/tests/testStoreHashIndex.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,6 +1,6 @@
 #define SQUID_UNIT_TEST 1
 
-#include "squid.h"
+#include "squid-old.h"
 
 #include "testStoreHashIndex.h"
 #include "Store.h"
diff -u -r -N squid-3.2.0.14/src/tests/testStoreSupport.cc squid-3.2.0.15/src/tests/testStoreSupport.cc
--- squid-3.2.0.14/src/tests/testStoreSupport.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/tests/testStoreSupport.cc	2012-02-06 04:52:31.000000000 +1300
@@ -32,7 +32,7 @@
  */
 
 #define SQUID_UNIT_TEST 1
-#include "config.h"
+#include "squid.h"
 #include "testStoreSupport.h"
 #include "event.h"
 #include "EventLoop.h"
diff -u -r -N squid-3.2.0.14/src/tests/testString.cc squid-3.2.0.15/src/tests/testString.cc
--- squid-3.2.0.14/src/tests/testString.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/tests/testString.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,5 +1,5 @@
 #define SQUID_UNIT_TEST 1
-#include "config.h"
+#include "squid.h"
 
 #include "testString.h"
 #include "SquidString.h"
diff -u -r -N squid-3.2.0.14/src/tests/TestSwapDir.cc squid-3.2.0.15/src/tests/TestSwapDir.cc
--- squid-3.2.0.14/src/tests/TestSwapDir.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/tests/TestSwapDir.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,6 +1,6 @@
-#include "config.h"
-
 #include "squid.h"
+
+#include "squid-old.h"
 #include "TestSwapDir.h"
 
 uint64_t
diff -u -r -N squid-3.2.0.14/src/tests/TestSwapDir.h squid-3.2.0.15/src/tests/TestSwapDir.h
--- squid-3.2.0.14/src/tests/TestSwapDir.h	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/tests/TestSwapDir.h	2012-02-06 04:52:31.000000000 +1300
@@ -1,7 +1,7 @@
 #ifndef TEST_TESTSWAPDIR
 #define TEST_TESTSWAPDIR
 
-#include "squid.h"
+#include "squid-old.h"
 #include "SwapDir.h"
 
 class TestSwapDir : public SwapDir
diff -u -r -N squid-3.2.0.14/src/tests/testUfs.cc squid-3.2.0.15/src/tests/testUfs.cc
--- squid-3.2.0.14/src/tests/testUfs.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/tests/testUfs.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,5 +1,5 @@
 #define SQUID_UNIT_TEST 1
-#include "config.h"
+#include "squid.h"
 #include "testUfs.h"
 #include "Store.h"
 #include "SwapDir.h"
diff -u -r -N squid-3.2.0.14/src/tests/testURL.cc squid-3.2.0.15/src/tests/testURL.cc
--- squid-3.2.0.14/src/tests/testURL.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/tests/testURL.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,5 +1,5 @@
 #define SQUID_UNIT_TEST 1
-#include "config.h"
+#include "squid.h"
 
 #include <cppunit/TestAssert.h>
 
diff -u -r -N squid-3.2.0.14/src/tests/testURLScheme.cc squid-3.2.0.15/src/tests/testURLScheme.cc
--- squid-3.2.0.14/src/tests/testURLScheme.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/tests/testURLScheme.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,6 +1,6 @@
 #define SQUID_UNIT_TEST 1
 
-#include "squid.h"
+#include "squid-old.h"
 
 #include <cppunit/TestAssert.h>
 
diff -u -r -N squid-3.2.0.14/src/time.cc squid-3.2.0.15/src/time.cc
--- squid-3.2.0.14/src/time.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/time.cc	2012-02-06 04:52:31.000000000 +1300
@@ -31,7 +31,7 @@
  *  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111, USA.
  *
  */
-#include "config.h"
+#include "squid.h"
 #include "SquidTime.h"
 
 struct timeval current_time;
diff -u -r -N squid-3.2.0.14/src/tools.cc squid-3.2.0.15/src/tools.cc
--- squid-3.2.0.14/src/tools.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/tools.cc	2012-02-06 04:52:31.000000000 +1300
@@ -32,7 +32,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "base/Subscription.h"
 #include "fde.h"
 #include "ICP.h"
@@ -610,7 +610,7 @@
 #if USE_SSL
 
     if (Config.Sockaddr.https && sa.IsAnyAddr())
-        sa = Config.Sockaddr.https->http.s;
+        sa = Config.Sockaddr.https->s;
 
 #endif
 
@@ -1258,18 +1258,23 @@
 int
 getMyPort(void)
 {
-    if (Config.Sockaddr.http) {
-        // skip any special mode ports
-        http_port_list *p = Config.Sockaddr.http;
-        while (p && (p->intercepted || p->accel || p->spoof_client_ip))
+    http_port_list *p = NULL;
+    if ((p = Config.Sockaddr.http)) {
+        // skip any special interception ports
+        while (p && (p->intercepted || p->spoof_client_ip))
             p = p->next;
         if (p)
             return p->s.GetPort();
     }
 
 #if USE_SSL
-    if (Config.Sockaddr.https)
-        return Config.Sockaddr.https->http.s.GetPort();
+    if ((p = Config.Sockaddr.https)) {
+        // skip any special interception ports
+        while (p && (p->intercepted || p->spoof_client_ip))
+            p = p->next;
+        if (p)
+            return p->s.GetPort();
+    }
 #endif
 
     debugs(21, DBG_CRITICAL, "ERROR: No forward-proxy ports configured.");
diff -u -r -N squid-3.2.0.14/src/tunnel.cc squid-3.2.0.15/src/tunnel.cc
--- squid-3.2.0.14/src/tunnel.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/tunnel.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "errorpage.h"
 #include "HttpRequest.h"
 #include "fde.h"
diff -u -r -N squid-3.2.0.14/src/typedefs.h squid-3.2.0.15/src/typedefs.h
--- squid-3.2.0.14/src/typedefs.h	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/typedefs.h	2012-02-06 04:52:31.000000000 +1300
@@ -31,7 +31,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 
 #ifndef SQUID_TYPEDEFS_H
 #define SQUID_TYPEDEFS_H
@@ -47,9 +47,6 @@
     size_t kb;
 } kb_t;
 
-struct http_port_list;
-struct https_port_list;
-
 typedef struct _close_handler close_handler;
 
 typedef struct _dread_ctrl dread_ctrl;
diff -u -r -N squid-3.2.0.14/src/ufsdump.cc squid-3.2.0.15/src/ufsdump.cc
--- squid-3.2.0.14/src/ufsdump.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/ufsdump.cc	2012-02-06 04:52:31.000000000 +1300
@@ -32,7 +32,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 #include "StoreMeta.h"
 #include "StoreMetaUnpacker.h"
 #include "Store.h"
diff -u -r -N squid-3.2.0.14/src/unlinkd.cc squid-3.2.0.15/src/unlinkd.cc
--- squid-3.2.0.14/src/unlinkd.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/unlinkd.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "SquidTime.h"
 #include "SwapDir.h"
 #include "fde.h"
@@ -242,9 +242,8 @@
 
     fd_note(unlinkd_rfd, "unlinkd -> squid");
 
-    commSetTimeout(unlinkd_rfd, -1, NULL, NULL);
-
-    commSetTimeout(unlinkd_wfd, -1, NULL, NULL);
+    commUnsetFdTimeout(unlinkd_rfd);
+    commUnsetFdTimeout(unlinkd_wfd);
 
     /*
     * unlinkd_rfd should already be non-blocking because of
diff -u -r -N squid-3.2.0.14/src/unlinkd_daemon.cc squid-3.2.0.15/src/unlinkd_daemon.cc
--- squid-3.2.0.14/src/unlinkd_daemon.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/unlinkd_daemon.cc	2012-02-06 04:52:31.000000000 +1300
@@ -34,7 +34,7 @@
 
 #define SQUID_HELPER 1
 
-#include "config.h"
+#include "squid.h"
 
 #if HAVE_PATHS_H
 #include <paths.h>
diff -u -r -N squid-3.2.0.14/src/url.cc squid-3.2.0.15/src/url.cc
--- squid-3.2.0.14/src/url.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/url.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 #include "URL.h"
 #include "HttpRequest.h"
 #include "URLScheme.h"
diff -u -r -N squid-3.2.0.14/src/URLScheme.cc squid-3.2.0.15/src/URLScheme.cc
--- squid-3.2.0.14/src/URLScheme.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/URLScheme.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 #include "URLScheme.h"
 #include "wordlist.h"
 
diff -u -r -N squid-3.2.0.14/src/urn.cc squid-3.2.0.15/src/urn.cc
--- squid-3.2.0.14/src/urn.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/urn.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "errorpage.h"
 #include "StoreClient.h"
 #include "Store.h"
diff -u -r -N squid-3.2.0.14/src/wccp2.cc squid-3.2.0.15/src/wccp2.cc
--- squid-3.2.0.14/src/wccp2.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/wccp2.cc	2012-02-06 04:52:31.000000000 +1300
@@ -30,7 +30,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 
 #if USE_WCCPv2
 
diff -u -r -N squid-3.2.0.14/src/wccp.cc squid-3.2.0.15/src/wccp.cc
--- squid-3.2.0.14/src/wccp.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/wccp.cc	2012-02-06 04:52:31.000000000 +1300
@@ -32,11 +32,11 @@
  *  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111, USA.
  *
  */
-#include "config.h"
+#include "squid.h"
 
 #if USE_WCCP
 
-#include "squid.h"
+#include "squid-old.h"
 #include "comm.h"
 #include "comm/Connection.h"
 #include "comm/Loops.h"
diff -u -r -N squid-3.2.0.14/src/whois.cc squid-3.2.0.15/src/whois.cc
--- squid-3.2.0.14/src/whois.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/whois.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "comm/Write.h"
 #include "errorpage.h"
 #include "Store.h"
diff -u -r -N squid-3.2.0.14/src/win32.cc squid-3.2.0.15/src/win32.cc
--- squid-3.2.0.14/src/win32.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/win32.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "squid_windows.h"
 
 #if _SQUID_MSWIN_
diff -u -r -N squid-3.2.0.14/src/WinSvc.cc squid-3.2.0.15/src/WinSvc.cc
--- squid-3.2.0.14/src/WinSvc.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/WinSvc.cc	2012-02-06 04:52:31.000000000 +1300
@@ -34,7 +34,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "squid_windows.h"
 
 #if _SQUID_MSWIN_
diff -u -r -N squid-3.2.0.14/src/wordlist.cc squid-3.2.0.15/src/wordlist.cc
--- squid-3.2.0.14/src/wordlist.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/wordlist.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 #include "wordlist.h"
 #include "MemBuf.h"
 
diff -u -r -N squid-3.2.0.14/src/wordlist.h squid-3.2.0.15/src/wordlist.h
--- squid-3.2.0.14/src/wordlist.h	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/src/wordlist.h	2012-02-06 04:52:31.000000000 +1300
@@ -32,7 +32,7 @@
 #ifndef SQUID_WORDLIST_H
 #define SQUID_WORDLIST_H
 
-#include "squid.h"
+#include "squid-old.h"
 #include "MemPool.h"
 
 class wordlist
diff -u -r -N squid-3.2.0.14/test-suite/debug.cc squid-3.2.0.15/test-suite/debug.cc
--- squid-3.2.0.14/test-suite/debug.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/test-suite/debug.cc	2012-02-06 04:52:31.000000000 +1300
@@ -34,7 +34,7 @@
  * Copyright (c) 2003  Robert Collins <robertc@squid-cache.org>
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "stmem.h"
 #include "mem_node.h"
 
diff -u -r -N squid-3.2.0.14/test-suite/ESIExpressions.cc squid-3.2.0.15/test-suite/ESIExpressions.cc
--- squid-3.2.0.14/test-suite/ESIExpressions.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/test-suite/ESIExpressions.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "esi/Expression.h"
 
 int
diff -u -r -N squid-3.2.0.14/test-suite/membanger.c squid-3.2.0.15/test-suite/membanger.c
--- squid-3.2.0.14/test-suite/membanger.c	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/test-suite/membanger.c	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "config.h"
+#include "squid.h"
 #include "hash.h"
 
 #if HAVE_UNISTD_H
diff -u -r -N squid-3.2.0.14/test-suite/mem_hdr_test.cc squid-3.2.0.15/test-suite/mem_hdr_test.cc
--- squid-3.2.0.14/test-suite/mem_hdr_test.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/test-suite/mem_hdr_test.cc	2012-02-06 04:52:31.000000000 +1300
@@ -34,7 +34,7 @@
  * Copyright (c) 2003  Robert Collins <robertc@squid-cache.org>
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "stmem.h"
 #include "mem_node.h"
 #include "Generic.h"
diff -u -r -N squid-3.2.0.14/test-suite/mem_node_test.cc squid-3.2.0.15/test-suite/mem_node_test.cc
--- squid-3.2.0.14/test-suite/mem_node_test.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/test-suite/mem_node_test.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "mem_node.h"
 
 #if HAVE_IOSTREAM
diff -u -r -N squid-3.2.0.14/test-suite/MemPoolTest.cc squid-3.2.0.15/test-suite/MemPoolTest.cc
--- squid-3.2.0.14/test-suite/MemPoolTest.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/test-suite/MemPoolTest.cc	2012-02-06 04:52:31.000000000 +1300
@@ -32,7 +32,7 @@
  * Copyright (c) 2003, Robert Collins <robertc@squid-cache.org>
  */
 
-#include "squid.h"
+#include "squid-old.h"
 
 #if USE_MEMPOOLS
 
diff -u -r -N squid-3.2.0.14/test-suite/refcount.cc squid-3.2.0.15/test-suite/refcount.cc
--- squid-3.2.0.14/test-suite/refcount.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/test-suite/refcount.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
  *
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "RefCount.h"
 
 class _ToRefCount :public RefCountable
diff -u -r -N squid-3.2.0.14/test-suite/splay.cc squid-3.2.0.15/test-suite/splay.cc
--- squid-3.2.0.14/test-suite/splay.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/test-suite/splay.cc	2012-02-06 04:52:31.000000000 +1300
@@ -5,7 +5,7 @@
  * http://bobo.link.cs.cmu.edu/cgi-bin/splay/splay-cgi.pl
  */
 
-#include "config.h"
+#include "squid.h"
 
 #if HAVE_STDIO_H
 #include <stdio.h>
diff -u -r -N squid-3.2.0.14/test-suite/StackTest.cc squid-3.2.0.15/test-suite/StackTest.cc
--- squid-3.2.0.14/test-suite/StackTest.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/test-suite/StackTest.cc	2012-02-06 04:52:31.000000000 +1300
@@ -34,7 +34,7 @@
  * Copyright (c) 2003  Robert Collins <robertc@squid-cache.org>
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "Stack.h"
 
 int
diff -u -r -N squid-3.2.0.14/test-suite/stub_debug.cc squid-3.2.0.15/test-suite/stub_debug.cc
--- squid-3.2.0.14/test-suite/stub_debug.cc	2011-12-13 01:29:37.000000000 +1300
+++ squid-3.2.0.15/test-suite/stub_debug.cc	2012-02-06 06:02:58.000000000 +1300
@@ -2,7 +2,7 @@
  * A stub implementation of the Debug.h API.
  * For use by test binaries which do not need the full context debugging
  */
-#include "config.h"
+#include "squid.h"
 #include "Debug.h"
 
 #if HAVE_STDIO_H
diff -u -r -N squid-3.2.0.14/test-suite/syntheticoperators.cc squid-3.2.0.15/test-suite/syntheticoperators.cc
--- squid-3.2.0.14/test-suite/syntheticoperators.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/test-suite/syntheticoperators.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
  * Copyright (c) 2003  Robert Collins <robertc@squid-cache.org>
  */
 
-#include "squid.h"
+#include "squid-old.h"
 #include "stmem.h"
 #include "mem_node.h"
 
diff -u -r -N squid-3.2.0.14/test-suite/tcp-banger2.c squid-3.2.0.15/test-suite/tcp-banger2.c
--- squid-3.2.0.14/test-suite/tcp-banger2.c	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/test-suite/tcp-banger2.c	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "config.h"
+#include "squid.h"
 
 /* $Id$
 
diff -u -r -N squid-3.2.0.14/test-suite/testheaders.sh squid-3.2.0.15/test-suite/testheaders.sh
--- squid-3.2.0.14/test-suite/testheaders.sh	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/test-suite/testheaders.sh	2012-02-06 04:52:31.000000000 +1300
@@ -24,7 +24,7 @@
     if [ ! -f "$t.o" -o $f -nt "$t.o" ]; then
         echo >$t.cc <<EOF
 /* This file is AUTOMATICALLY GENERATED. DO NOT ALTER IT */
-#include "config.h"
+#include "squid.h"
 #include "${f}"
 int main( int argc, char* argv[] ) { return 0; }
 EOF
diff -u -r -N squid-3.2.0.14/test-suite/test_tools.cc squid-3.2.0.15/test-suite/test_tools.cc
--- squid-3.2.0.14/test-suite/test_tools.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/test-suite/test_tools.cc	2012-02-06 04:52:31.000000000 +1300
@@ -5,7 +5,7 @@
 // XXX: This file is made of large pieces of src/tools.cc
 // with only a few minor modifications. TODO: redesign or delete.
 
-#include "squid.h"
+#include "squid-old.h"
 
 void
 xassert(const char *msg, const char *file, int line)
diff -u -r -N squid-3.2.0.14/test-suite/VirtualDeleteOperator.cc squid-3.2.0.15/test-suite/VirtualDeleteOperator.cc
--- squid-3.2.0.14/test-suite/VirtualDeleteOperator.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/test-suite/VirtualDeleteOperator.cc	2012-02-06 04:52:31.000000000 +1300
@@ -33,7 +33,7 @@
  * Copyright (c) 2003  Robert Collins <robertc@squid-cache.org>
  */
 
-#include "squid.h"
+#include "squid-old.h"
 
 #if HAVE_IOSTREAM
 #include <iostream>
diff -u -r -N squid-3.2.0.14/tools/cachemgr.cc squid-3.2.0.15/tools/cachemgr.cc
--- squid-3.2.0.14/tools/cachemgr.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/tools/cachemgr.cc	2012-02-06 04:52:31.000000000 +1300
@@ -30,7 +30,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 #include "base64.h"
 #include "getfullhostname.h"
 #include "html_quote.h"
@@ -274,13 +274,40 @@
     if (!host || !strlen(host))
         host = "";
 
+    fp = fopen("cachemgr.conf", "r");
+
+    if (fp == NULL)
+        fp = fopen(DEFAULT_CACHEMGR_CONFIG, "r");
+
+    if (fp == NULL)
+        printf("X-Error: message=\"Unable to open config %s\"", DEFAULT_CACHEMGR_CONFIG);
+
     printf("Content-Type: text/html\r\n\r\n");
 
     printf("<!DOCTYPE HTML PUBLIC \"-//W3C//DTD HTML 4.01 Transitional//EN\" \"http://www.w3.org/TR/html4/loose.dtd\">\n");
 
     printf("<HTML><HEAD><TITLE>Cache Manager Interface</TITLE>\n");
 
-    printf("<STYLE type=\"text/css\"><!--BODY{background-color:#ffffff;font-family:verdana,sans-serif}--></STYLE></HEAD>\n");
+    printf("<STYLE type=\"text/css\"><!--BODY{background-color:#ffffff;font-family:verdana,sans-serif}--></STYLE>\n");
+
+    printf("<script type=\"text/javascript\">\n");
+    printf("function TS(t, s) {\n");
+    printf(" var x = new XMLHttpRequest();\n");
+    printf(" x.open('GET', 'http' + s + '://' + t + '/squid-internal-mgr/', true);\n");
+    printf(" x.onreadystatechange=function() {\n");
+    printf("  if (x.readyState==4) {\n");
+    printf("   if ((x.status>=200 && x.status <= 299) || x.status==401) {\n");
+    printf("    var v = x.getResponseHeader('Server');\n");
+    printf("    if (v.substring(0,8) == 'squid/3.' && (v[8]=='H' || parseInt(v.substring(8)) >= 2)) {\n");
+    printf("     var d = document.getElementById('H' + s + 'mgr');\n");
+    printf("     if (d.innerHTML == '') d.innerHTML = '<h2>HTTP' + (s=='s'?'S':'') + ' Managed Proxies</h2>';\n");
+    printf("     d.innerHTML = d.innerHTML + '<p>Host: <a href=\"http' + s + '://' + t + '/squid-internal-mgr/\">' + t + '</a></p>';\n");
+    printf(" }}}}\n");
+    printf(" x.send(null);\n");
+    printf("}\n");
+    printf("</script>\n");
+
+    printf("</HEAD>\n");
 
     printf("<BODY><H1>Cache Manager Interface</H1>\n");
 
@@ -290,16 +317,15 @@
 
     printf("<HR noshade size=\"1px\">\n");
 
+    printf("<div id=\"Hsmgr\"></div>\n");
+    printf("<div id=\"Hmgr\"></div>\n");
+    printf("<div id=\"Cmgr\">\n");
+    printf("<h2>CGI Managed Proxies</h2>\n");
     printf("<FORM METHOD=\"POST\" ACTION=\"%s\">\n", script_name);
 
     printf("<TABLE BORDER=\"0\" CELLPADDING=\"10\" CELLSPACING=\"1\">\n");
 
 
-    fp = fopen("cachemgr.conf", "r");
-
-    if (fp == NULL)
-        fp = fopen(DEFAULT_CACHEMGR_CONFIG, "r");
-
     if (fp != NULL) {
         int servers = 0;
         char config_line[BUFSIZ];
@@ -331,9 +357,8 @@
             if (!comment || !*comment)
                 comment = server;
 
-            if (!servers) {
-                printf("<TR><TH ALIGN=\"left\">Cache Server:</TH><TD><SELECT NAME=\"server\">\n");
-            }
+            if (!servers)
+                printf("<TR><TH ALIGN=\"left\">Cache Server:</TH><TD><SELECT id=\"server\" NAME=\"server\">\n");
 
             printf("<OPTION VALUE=\"%s\"%s>%s</OPTION>\n", server, (servers || *host) ? "" : " SELECTED", comment);
             servers++;
@@ -377,7 +402,14 @@
 
     printf("<INPUT TYPE=\"submit\" VALUE=\"Continue...\">\n");
 
-    printf("</FORM>\n");
+    printf("</FORM></div>\n");
+
+    printf("<script type=\"text/javascript\">\n");
+    printf("var s = document.getElementById(\"server\");\n");
+    printf("for (var i = 0; i < s.childElementCount; i++) {\n");
+    printf(" TS(s.children[i].value, '');\n");
+    printf(" TS(s.children[i].value, 's');\n");
+    printf("}</script>\n");
 
     print_trailer();
 }
diff -u -r -N squid-3.2.0.14/tools/purge/conffile.cc squid-3.2.0.15/tools/purge/conffile.cc
--- squid-3.2.0.14/tools/purge/conffile.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/tools/purge/conffile.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "config.h"
+#include "squid.h"
 
 //
 // $Id$
diff -u -r -N squid-3.2.0.14/tools/purge/convert.cc squid-3.2.0.15/tools/purge/convert.cc
--- squid-3.2.0.14/tools/purge/convert.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/tools/purge/convert.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "config.h"
+#include "squid.h"
 
 //
 // $Id$
diff -u -r -N squid-3.2.0.14/tools/purge/copyout.cc squid-3.2.0.15/tools/purge/copyout.cc
--- squid-3.2.0.14/tools/purge/copyout.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/tools/purge/copyout.cc	2012-02-06 04:52:31.000000000 +1300
@@ -42,7 +42,7 @@
 #pragma implementation
 #endif
 
-#include "config.h"
+#include "squid.h"
 #include "copyout.hh"
 
 //#include <assert.h>
diff -u -r -N squid-3.2.0.14/tools/purge/purge.cc squid-3.2.0.15/tools/purge/purge.cc
--- squid-3.2.0.14/tools/purge/purge.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/tools/purge/purge.cc	2012-02-06 04:52:31.000000000 +1300
@@ -97,7 +97,7 @@
 #pragma implementation
 #endif
 
-#include "config.h"
+#include "squid.h"
 // for xstrdup
 #include "util.h"
 
diff -u -r -N squid-3.2.0.14/tools/purge/signal.cc squid-3.2.0.15/tools/purge/signal.cc
--- squid-3.2.0.14/tools/purge/signal.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/tools/purge/signal.cc	2012-02-06 04:52:31.000000000 +1300
@@ -49,7 +49,7 @@
 #pragma implementation
 #endif
 
-#include "config.h"
+#include "squid.h"
 #include "signal.hh"
 
 //#include <sys/types.h>
diff -u -r -N squid-3.2.0.14/tools/purge/signal.hh squid-3.2.0.15/tools/purge/signal.hh
--- squid-3.2.0.14/tools/purge/signal.hh	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/tools/purge/signal.hh	2012-02-06 04:52:31.000000000 +1300
@@ -51,7 +51,7 @@
 #ifndef _SIGNAL_HH
 #define _SIGNAL_HH
 
-#include "config.h"
+#include "squid.h"
 
 #if HAVE_SIGNAL_H
 #include <signal.h>
diff -u -r -N squid-3.2.0.14/tools/purge/socket.cc squid-3.2.0.15/tools/purge/socket.cc
--- squid-3.2.0.14/tools/purge/socket.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/tools/purge/socket.cc	2012-02-06 04:52:31.000000000 +1300
@@ -1,4 +1,4 @@
-#include "config.h"
+#include "squid.h"
 
 //
 // $Id$
diff -u -r -N squid-3.2.0.14/tools/purge/squid-tlv.cc squid-3.2.0.15/tools/purge/squid-tlv.cc
--- squid-3.2.0.14/tools/purge/squid-tlv.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/tools/purge/squid-tlv.cc	2012-02-06 04:52:31.000000000 +1300
@@ -39,7 +39,7 @@
 #pragma implementation
 #endif
 
-#include "config.h"
+#include "squid.h"
 //#include <assert.h>
 #include "squid-tlv.hh"
 
diff -u -r -N squid-3.2.0.14/tools/squidclient.cc squid-3.2.0.15/tools/squidclient.cc
--- squid-3.2.0.14/tools/squidclient.cc	2011-12-13 00:08:18.000000000 +1300
+++ squid-3.2.0.15/tools/squidclient.cc	2012-02-06 04:52:31.000000000 +1300
@@ -32,7 +32,7 @@
  *
  */
 
-#include "config.h"
+#include "squid.h"
 #include "base64.h"
 #include "ip/Address.h"
 #include "rfc1123.h"
diff -u -r -N squid-3.2.0.14/tools/stub_debug.cc squid-3.2.0.15/tools/stub_debug.cc
--- squid-3.2.0.14/tools/stub_debug.cc	2011-12-13 01:29:37.000000000 +1300
+++ squid-3.2.0.15/tools/stub_debug.cc	2012-02-06 06:02:58.000000000 +1300
@@ -2,7 +2,7 @@
  * A stub implementation of the Debug.h API.
  * For use by test binaries which do not need the full context debugging
  */
-#include "config.h"
+#include "squid.h"
 #include "Debug.h"
 
 #if HAVE_STDIO_H
diff -u -r -N squid-3.2.0.14/tools/test_tools.cc squid-3.2.0.15/tools/test_tools.cc
--- squid-3.2.0.14/tools/test_tools.cc	2011-12-13 01:29:37.000000000 +1300
+++ squid-3.2.0.15/tools/test_tools.cc	2012-02-06 06:02:58.000000000 +1300
@@ -5,7 +5,7 @@
 // XXX: This file is made of large pieces of src/tools.cc
 // with only a few minor modifications. TODO: redesign or delete.
 
-#include "squid.h"
+#include "squid-old.h"
 
 void
 xassert(const char *msg, const char *file, int line)
diff -u -r -N squid-3.2.0.14/tools/time.cc squid-3.2.0.15/tools/time.cc
--- squid-3.2.0.14/tools/time.cc	2011-12-13 01:29:37.000000000 +1300
+++ squid-3.2.0.15/tools/time.cc	2012-02-06 06:02:58.000000000 +1300
@@ -31,7 +31,7 @@
  *  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111, USA.
  *
  */
-#include "config.h"
+#include "squid.h"
 #include "SquidTime.h"
 
 struct timeval current_time;
