httpd-cvs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From j..@apache.org
Subject svn commit: r332306 [5/14] - in /httpd/httpd/trunk: modules/aaa/ modules/arch/netware/ modules/arch/win32/ modules/cache/ modules/dav/fs/ modules/dav/lock/ modules/dav/main/ modules/debug/ modules/echo/ modules/experimental/ modules/filters/ modules/ge...
Date Thu, 10 Nov 2005 15:13:26 GMT
Modified: httpd/httpd/trunk/modules/http/http_protocol.c
URL: http://svn.apache.org/viewcvs/httpd/httpd/trunk/modules/http/http_protocol.c?rev=332306&r1=332305&r2=332306&view=diff
==============================================================================
--- httpd/httpd/trunk/modules/http/http_protocol.c (original)
+++ httpd/httpd/trunk/modules/http/http_protocol.c Thu Nov 10 07:11:44 2005
@@ -459,7 +459,7 @@
     if (methname == NULL) {
         return M_INVALID;
     }
-    
+
     /* Check if the method was previously registered.  If it was
      * return the associated method number.
      */
@@ -467,7 +467,7 @@
                                   APR_HASH_KEY_STRING);
     if (methnum != NULL)
         return *methnum;
-        
+
     if (cur_method_number > METHOD_NUMBER_LAST) {
         /* The method registry  has run out of dynamically
          * assignable method numbers. Log this and return M_INVALID.
@@ -822,9 +822,9 @@
     else if (!r->content_type || strcmp(r->content_type, ct)) {
         r->content_type = ct;
 
-        /* Insert filters requested by the AddOutputFiltersByType 
-         * configuration directive. Content-type filters must be 
-         * inserted after the content handlers have run because 
+        /* Insert filters requested by the AddOutputFiltersByType
+         * configuration directive. Content-type filters must be
+         * inserted after the content handlers have run because
          * only then, do we reliably know the content-type.
          */
         ap_add_output_filters_by_type(r);
@@ -1107,7 +1107,7 @@
      */
     r->eos_sent = 0;
 
-    /* and we need to get rid of any RESOURCE filters that might be lurking 
+    /* and we need to get rid of any RESOURCE filters that might be lurking
      * around, thinking they are in the middle of the original request
      */
 
@@ -1196,11 +1196,11 @@
          * as a text message, so first check the custom response
          * string to ensure that it is a text-string (using the
          * same test used in ap_die(), i.e. does it start with a ").
-         * 
-         * If it's not a text string, we've got a recursive error or 
+         *
+         * If it's not a text string, we've got a recursive error or
          * an external redirect.  If it's a recursive error, ap_die passes
-         * us the second error code so we can write both, and has already 
-         * backed up to the original error.  If it's an external redirect, 
+         * us the second error code so we can write both, and has already
+         * backed up to the original error.  If it's an external redirect,
          * it hasn't happened yet; we may never know if it fails.
          */
         if (custom_response[0] == '\"') {

Modified: httpd/httpd/trunk/modules/http/http_request.c
URL: http://svn.apache.org/viewcvs/httpd/httpd/trunk/modules/http/http_request.c?rev=332306&r1=332305&r2=332306&view=diff
==============================================================================
--- httpd/httpd/trunk/modules/http/http_request.c (original)
+++ httpd/httpd/trunk/modules/http/http_request.c Thu Nov 10 07:11:44 2005
@@ -55,12 +55,12 @@
  * Mainline request processing...
  */
 
-/* XXX A cleaner and faster way to do this might be to pass the request_rec 
- * down the filter chain as a parameter.  It would need to change for 
- * subrequest vs. main request filters; perhaps the subrequest filter could 
+/* XXX A cleaner and faster way to do this might be to pass the request_rec
+ * down the filter chain as a parameter.  It would need to change for
+ * subrequest vs. main request filters; perhaps the subrequest filter could
  * make the switch.
  */
-static void update_r_in_filters(ap_filter_t *f, 
+static void update_r_in_filters(ap_filter_t *f,
                                 request_rec *from,
                                 request_rec *to)
 {
@@ -103,8 +103,8 @@
         if (r_1st_err != r) {
             /* The recursive error was caused by an ErrorDocument specifying
              * an internal redirect to a bad URI.  ap_internal_redirect has
-             * changed the filter chains to point to the ErrorDocument's 
-             * request_rec.  Back out those changes so we can safely use the 
+             * changed the filter chains to point to the ErrorDocument's
+             * request_rec.  Back out those changes so we can safely use the
              * original failing request_rec to send the canned error message.
              *
              * ap_send_error_response gets rid of existing resource filters
@@ -168,7 +168,7 @@
              * more informative (than the plain canned) messages to us.
              * Propagate them to ErrorDocuments via the ERROR_NOTES variable:
              */
-            if ((error_notes = apr_table_get(r->notes, 
+            if ((error_notes = apr_table_get(r->notes,
                                              "error-notes")) != NULL) {
                 apr_table_setn(r->subprocess_env, "ERROR_NOTES", error_notes);
             }
@@ -196,7 +196,7 @@
     /* ### is zero correct? that means "read one line" */
     if (c->keepalive != AP_CONN_CLOSE) {
         apr_bucket_brigade *bb = apr_brigade_create(c->pool, c->bucket_alloc);
-        if (ap_get_brigade(c->input_filters, bb, AP_MODE_EATCRLF, 
+        if (ap_get_brigade(c->input_filters, bb, AP_MODE_EATCRLF,
                        APR_NONBLOCK_READ, 0) != APR_SUCCESS) {
             c->data_in_input_filters = 0;  /* we got APR_EOF or an error */
         }
@@ -217,15 +217,15 @@
     /* Give quick handlers a shot at serving the request on the fast
      * path, bypassing all of the other Apache hooks.
      *
-     * This hook was added to enable serving files out of a URI keyed 
-     * content cache ( e.g., Mike Abbott's Quick Shortcut Cache, 
+     * This hook was added to enable serving files out of a URI keyed
+     * content cache ( e.g., Mike Abbott's Quick Shortcut Cache,
      * described here: http://oss.sgi.com/projects/apache/mod_qsc.html )
      *
      * It may have other uses as well, such as routing requests directly to
      * content handlers that have the ability to grok HTTP and do their
-     * own access checking, etc (e.g. servlet engines). 
-     * 
-     * Use this hook with extreme care and only if you know what you are 
+     * own access checking, etc (e.g. servlet engines).
+     *
+     * Use this hook with extreme care and only if you know what you are
      * doing.
      */
     if (ap_extended_status)
@@ -388,7 +388,7 @@
         ap_add_output_filter_handle(ap_subreq_core_filter_handle,
                                     NULL, new, new->connection);
     }
-    
+
     update_r_in_filters(new->input_filters, r, new);
     update_r_in_filters(new->output_filters, r, new);
 
@@ -517,7 +517,7 @@
     }
 }
 
-AP_DECLARE(void) ap_allow_methods(request_rec *r, int reset, ...) 
+AP_DECLARE(void) ap_allow_methods(request_rec *r, int reset, ...)
 {
     const char *method;
     va_list methods;

Modified: httpd/httpd/trunk/modules/http/mod_mime.c
URL: http://svn.apache.org/viewcvs/httpd/httpd/trunk/modules/http/mod_mime.c?rev=332306&r1=332305&r2=332306&view=diff
==============================================================================
--- httpd/httpd/trunk/modules/http/mod_mime.c (original)
+++ httpd/httpd/trunk/modules/http/mod_mime.c Thu Nov 10 07:11:44 2005
@@ -16,9 +16,9 @@
 
 /*
  * http_mime.c: Sends/gets MIME headers for requests
- * 
+ *
  * Rob McCool
- * 
+ *
  */
 
 #include "apr.h"
@@ -39,16 +39,16 @@
 /* XXXX - fix me / EBCDIC
  *        there was a cludge here which would use its
  *        own version apr_isascii(). Indicating that
- *        on some platforms that might be needed. 
+ *        on some platforms that might be needed.
  *
- *        #define OS_ASC(c) (c)             -- for mere mortals 
+ *        #define OS_ASC(c) (c)             -- for mere mortals
  *     or
  *        #define OS_ASC(c) (ebcdic2ascii[c]) -- for dino's
  *
  *        #define apr_isascii(c) ((OS_ASC(c) & 0x80) == 0)
  */
 
-/* XXXXX - fix me - See note with NOT_PROXY 
+/* XXXXX - fix me - See note with NOT_PROXY
  */
 
 typedef struct attrib_info {
@@ -83,13 +83,13 @@
     char *default_language;     /* Language if no AddLanguage ext found */
 
     int multimatch;       /* Extensions to include in multiview matching
-                           * for filenames, e.g. Filters and Handlers 
+                           * for filenames, e.g. Filters and Handlers
                            */
     int use_path_info;    /* If set to 0, only use filename.
                            * If set to 1, append PATH_INFO to filename for
                            *   lookups.
                            * If set to 2, this value is unset and is
-                           *   effectively 0.  
+                           *   effectively 0.
                            */
 } mime_dir_config;
 
@@ -170,9 +170,9 @@
     return new_info;
 }
 
-/* Member is the offset within an extension_info of the pointer to reset 
+/* Member is the offset within an extension_info of the pointer to reset
  */
-static void remove_items(apr_pool_t *p, apr_array_header_t *remove, 
+static void remove_items(apr_pool_t *p, apr_array_header_t *remove,
                          apr_hash_t *mappings)
 {
     attrib_info *suffix = (attrib_info *) remove->elts;
@@ -184,7 +184,7 @@
         if (exinfo && *(const char**)((char *)exinfo + suffix[i].offset)) {
             extension_info *copyinfo = exinfo;
             exinfo = (extension_info*)apr_palloc(p, sizeof(*exinfo));
-            apr_hash_set(mappings, suffix[i].name, 
+            apr_hash_set(mappings, suffix[i].name,
                          APR_HASH_KEY_STRING, exinfo);
             memcpy(exinfo, copyinfo, sizeof(*exinfo));
             *(const char**)((char *)exinfo + suffix[i].offset) = NULL;
@@ -243,7 +243,7 @@
     return new;
 }
 
-static const char *add_extension_info(cmd_parms *cmd, void *m_, 
+static const char *add_extension_info(cmd_parms *cmd, void *m_,
                                       const char *value_, const char* ext)
 {
     mime_dir_config *m=m_;
@@ -279,7 +279,7 @@
  * This keeps the association from being inherited, but not
  * from being re-added at a subordinate level.
  */
-static const char *remove_extension_info(cmd_parms *cmd, void *m_, 
+static const char *remove_extension_info(cmd_parms *cmd, void *m_,
                                          const char *ext)
 {
     mime_dir_config *m = (mime_dir_config *) m_;
@@ -309,7 +309,7 @@
     return NULL;
 }
 
-static const char *multiviews_match(cmd_parms *cmd, void *m_, 
+static const char *multiviews_match(cmd_parms *cmd, void *m_,
                                     const char *include)
 {
     mime_dir_config *m = (mime_dir_config *) m_;
@@ -329,14 +329,14 @@
         m->multimatch |= MULTIMATCH_NEGOTIATED;
     }
     else if (strcasecmp(include, "Filters") == 0) {
-        if (m->multimatch && (m->multimatch & (MULTIMATCH_NEGOTIATED 
+        if (m->multimatch && (m->multimatch & (MULTIMATCH_NEGOTIATED
                                              | MULTIMATCH_ANY))) {
             return "Filters is incompatible with Any and NegotiatedOnly";
         }
         m->multimatch |= MULTIMATCH_FILTERS;
     }
     else if (strcasecmp(include, "Handlers") == 0) {
-        if (m->multimatch && (m->multimatch & (MULTIMATCH_NEGOTIATED 
+        if (m->multimatch && (m->multimatch & (MULTIMATCH_NEGOTIATED
                                              | MULTIMATCH_ANY))) {
             return "Handlers is incompatible with Any and NegotiatedOnly";
         }
@@ -351,54 +351,54 @@
 
 static const command_rec mime_cmds[] =
 {
-    AP_INIT_ITERATE2("AddCharset", add_extension_info, 
+    AP_INIT_ITERATE2("AddCharset", add_extension_info,
         (void *)APR_OFFSETOF(extension_info, charset_type), OR_FILEINFO,
         "a charset (e.g., iso-2022-jp), followed by one or more "
         "file extensions"),
-    AP_INIT_ITERATE2("AddEncoding", add_extension_info, 
+    AP_INIT_ITERATE2("AddEncoding", add_extension_info,
         (void *)APR_OFFSETOF(extension_info, encoding_type), OR_FILEINFO,
         "an encoding (e.g., gzip), followed by one or more file extensions"),
-    AP_INIT_ITERATE2("AddHandler", add_extension_info, 
+    AP_INIT_ITERATE2("AddHandler", add_extension_info,
         (void *)APR_OFFSETOF(extension_info, handler), OR_FILEINFO,
         "a handler name followed by one or more file extensions"),
-    AP_INIT_ITERATE2("AddInputFilter", add_extension_info, 
+    AP_INIT_ITERATE2("AddInputFilter", add_extension_info,
         (void *)APR_OFFSETOF(extension_info, input_filters), OR_FILEINFO,
         "input filter name (or ; delimited names) followed by one or "
         "more file extensions"),
-    AP_INIT_ITERATE2("AddLanguage", add_extension_info, 
+    AP_INIT_ITERATE2("AddLanguage", add_extension_info,
         (void *)APR_OFFSETOF(extension_info, language_type), OR_FILEINFO,
         "a language (e.g., fr), followed by one or more file extensions"),
-    AP_INIT_ITERATE2("AddOutputFilter", add_extension_info, 
-        (void *)APR_OFFSETOF(extension_info, output_filters), OR_FILEINFO, 
+    AP_INIT_ITERATE2("AddOutputFilter", add_extension_info,
+        (void *)APR_OFFSETOF(extension_info, output_filters), OR_FILEINFO,
         "output filter name (or ; delimited names) followed by one or "
         "more file extensions"),
-    AP_INIT_ITERATE2("AddType", add_extension_info, 
-        (void *)APR_OFFSETOF(extension_info, forced_type), OR_FILEINFO, 
+    AP_INIT_ITERATE2("AddType", add_extension_info,
+        (void *)APR_OFFSETOF(extension_info, forced_type), OR_FILEINFO,
         "a mime type followed by one or more file extensions"),
     AP_INIT_TAKE1("DefaultLanguage", ap_set_string_slot,
         (void*)APR_OFFSETOF(mime_dir_config, default_language), OR_FILEINFO,
         "language to use for documents with no other language file extension"),
     AP_INIT_ITERATE("MultiviewsMatch", multiviews_match, NULL, OR_FILEINFO,
         "NegotiatedOnly (default), Handlers and/or Filters, or Any"),
-    AP_INIT_ITERATE("RemoveCharset", remove_extension_info, 
+    AP_INIT_ITERATE("RemoveCharset", remove_extension_info,
         (void *)APR_OFFSETOF(extension_info, charset_type), OR_FILEINFO,
         "one or more file extensions"),
-    AP_INIT_ITERATE("RemoveEncoding", remove_extension_info, 
+    AP_INIT_ITERATE("RemoveEncoding", remove_extension_info,
         (void *)APR_OFFSETOF(extension_info, encoding_type), OR_FILEINFO,
         "one or more file extensions"),
-    AP_INIT_ITERATE("RemoveHandler", remove_extension_info, 
+    AP_INIT_ITERATE("RemoveHandler", remove_extension_info,
         (void *)APR_OFFSETOF(extension_info, handler), OR_FILEINFO,
         "one or more file extensions"),
-    AP_INIT_ITERATE("RemoveInputFilter", remove_extension_info, 
+    AP_INIT_ITERATE("RemoveInputFilter", remove_extension_info,
         (void *)APR_OFFSETOF(extension_info, input_filters), OR_FILEINFO,
         "one or more file extensions"),
-    AP_INIT_ITERATE("RemoveLanguage", remove_extension_info, 
+    AP_INIT_ITERATE("RemoveLanguage", remove_extension_info,
         (void *)APR_OFFSETOF(extension_info, language_type), OR_FILEINFO,
         "one or more file extensions"),
-    AP_INIT_ITERATE("RemoveOutputFilter", remove_extension_info, 
+    AP_INIT_ITERATE("RemoveOutputFilter", remove_extension_info,
         (void *)APR_OFFSETOF(extension_info, output_filters), OR_FILEINFO,
         "one or more file extensions"),
-    AP_INIT_ITERATE("RemoveType", remove_extension_info, 
+    AP_INIT_ITERATE("RemoveType", remove_extension_info,
         (void *)APR_OFFSETOF(extension_info, forced_type), OR_FILEINFO,
         "one or more file extensions"),
     AP_INIT_TAKE1("TypesConfig", set_types_config, NULL, RSRC_CONF,
@@ -426,15 +426,15 @@
     types_confname = ap_server_root_relative(p, types_confname);
     if (!types_confname) {
         ap_log_error(APLOG_MARK, APLOG_ERR, APR_EBADPATH, s,
-                     "Invalid mime types config path %s", 
+                     "Invalid mime types config path %s",
                      (const char *)ap_get_module_config(s->module_config,
                                                         &mime_module));
         return HTTP_INTERNAL_SERVER_ERROR;
     }
-    if ((status = ap_pcfg_openfile(&f, ptemp, types_confname)) 
+    if ((status = ap_pcfg_openfile(&f, ptemp, types_confname))
                 != APR_SUCCESS) {
         ap_log_error(APLOG_MARK, APLOG_ERR, status, s,
-                     "could not open mime types config file %s.", 
+                     "could not open mime types config file %s.",
                      types_confname);
         return HTTP_INTERNAL_SERVER_ERROR;
     }
@@ -781,7 +781,7 @@
     ext = ap_getword(r->pool, &fn, '.');
     *((const char **)apr_array_push(exception_list)) = ext;
 
-    /* Parse filename extensions which can be in any order 
+    /* Parse filename extensions which can be in any order
      */
     while (*fn && (ext = ap_getword(r->pool, &fn, '.'))) {
         const extension_info *exinfo = NULL;
@@ -848,7 +848,7 @@
             }
             /* The following extensions are not 'Found'.  That is, they don't
              * make any contribution to metadata negotation, so they must have
-             * been explicitly requested by name. 
+             * been explicitly requested by name.
              */
             if (exinfo->handler && r->proxyreq == PROXYREQ_NONE) {
                 r->handler = exinfo->handler;
@@ -862,7 +862,7 @@
              */
             if (exinfo->input_filters && r->proxyreq == PROXYREQ_NONE) {
                 const char *filter, *filters = exinfo->input_filters;
-                while (*filters 
+                while (*filters
                     && (filter = ap_getword(r->pool, &filters, ';'))) {
                     ap_add_input_filter(filter, NULL, r, r->connection);
                 }
@@ -872,7 +872,7 @@
             }
             if (exinfo->output_filters && r->proxyreq == PROXYREQ_NONE) {
                 const char *filter, *filters = exinfo->output_filters;
-                while (*filters 
+                while (*filters
                     && (filter = ap_getword(r->pool, &filters, ';'))) {
                     ap_add_output_filter(filter, NULL, r, r->connection);
                 }
@@ -896,7 +896,7 @@
      * skip the notes to alert mod_negotiation we are clueless.
      */
     if (found_metadata) {
-        apr_table_setn(r->notes, "ap-mime-exceptions-list", 
+        apr_table_setn(r->notes, "ap-mime-exceptions-list",
                        (void *)exception_list);
     }
 
@@ -972,7 +972,7 @@
 {
     ap_hook_post_config(mime_post_config,NULL,NULL,APR_HOOK_MIDDLE);
     ap_hook_type_checker(find_ct,NULL,NULL,APR_HOOK_MIDDLE);
-    /* 
+    /*
      * this hook seems redundant ... is there any reason a type checker isn't
      * allowed to do this already?  I'd think that fixups in general would be
      * the last opportunity to get the filters right.

Modified: httpd/httpd/trunk/modules/ldap/util_ldap.c
URL: http://svn.apache.org/viewcvs/httpd/httpd/trunk/modules/ldap/util_ldap.c?rev=332306&r1=332305&r2=332306&view=diff
==============================================================================
--- httpd/httpd/trunk/modules/ldap/util_ldap.c (original)
+++ httpd/httpd/trunk/modules/ldap/util_ldap.c Thu Nov 10 07:11:44 2005
@@ -16,9 +16,9 @@
 
 /*
  * util_ldap.c: LDAP things
- * 
+ *
  * Original code from auth_ldap module for Apache v1.3:
- * Copyright 1998, 1999 Enbridge Pipelines Inc. 
+ * Copyright 1998, 1999 Enbridge Pipelines Inc.
  * Copyright 1999-2001 Dave Carrigan
  */
 
@@ -92,7 +92,7 @@
 static int util_ldap_handler(request_rec *r)
 {
     util_ldap_state_t *st = (util_ldap_state_t *)
-                            ap_get_module_config(r->server->module_config, 
+                            ap_get_module_config(r->server->module_config,
                                                  &ldap_module);
 
     r->allowed |= (1 << M_GET);
@@ -193,7 +193,7 @@
 
         /* unlock this entry */
         uldap_connection_close(ldc);
-    
+
     }
 
     return APR_SUCCESS;
@@ -206,7 +206,7 @@
  *
  * Returns LDAP_SUCCESS on success; and an error code on failure
  */
-static int uldap_connection_open(request_rec *r, 
+static int uldap_connection_open(request_rec *r,
                                  util_ldap_connection_t *ldc)
 {
     int rc = 0;
@@ -214,7 +214,7 @@
     int version  = LDAP_VERSION3;
     apr_ldap_err_t *result = NULL;
     struct timeval timeOut = {10,0};    /* 10 second connection timeout */
-    util_ldap_state_t *st = 
+    util_ldap_state_t *st =
         (util_ldap_state_t *)ap_get_module_config(r->server->module_config,
         &ldap_module);
 
@@ -279,7 +279,7 @@
 
         /* switch on SSL/TLS */
         if (APR_LDAP_NONE != ldc->secure) {
-            apr_ldap_set_option(ldc->pool, ldc->ldap, 
+            apr_ldap_set_option(ldc->pool, ldc->ldap,
                                 APR_LDAP_OPT_TLS, &ldc->secure, &(result));
             if (LDAP_SUCCESS != result->rc) {
                 ldap_unbind_s(ldc->ldap);
@@ -298,7 +298,7 @@
 
 /*XXX All of the #ifdef's need to be removed once apr-util 1.2 is released */
 #ifdef APR_LDAP_OPT_VERIFY_CERT
-        apr_ldap_set_option(ldc->pool, ldc->ldap, 
+        apr_ldap_set_option(ldc->pool, ldc->ldap,
                             APR_LDAP_OPT_VERIFY_CERT, &(st->verify_svr_cert), &(result));
 #else
 #if defined(LDAPSSL_VERIFY_SERVER)
@@ -326,7 +326,7 @@
         if (st->connectionTimeout > 0) {
             timeOut.tv_sec = st->connectionTimeout;
         }
-    
+
         if (st->connectionTimeout >= 0) {
             rc = apr_ldap_set_option(ldc->pool, ldc->ldap, LDAP_OPT_NETWORK_TIMEOUT,
                                      (void *)&timeOut, &(result));
@@ -337,14 +337,14 @@
         }
 #endif
 
-    
+
     }
 
 
     /* loop trying to bind up to 10 times if LDAP_SERVER_DOWN error is
      * returned.  Break out of the loop on Success or any other error.
      *
-     * NOTE: Looping is probably not a great idea. If the server isn't 
+     * NOTE: Looping is probably not a great idea. If the server isn't
      * responding the chances it will respond after a few tries are poor.
      * However, the original code looped and it only happens on
      * the error condition.
@@ -382,7 +382,7 @@
  *
  * Returns 1 on compare failure, 0 otherwise.
  */
-static int compare_client_certs(apr_array_header_t *srcs, 
+static int compare_client_certs(apr_array_header_t *srcs,
                                 apr_array_header_t *dests)
 {
     int i = 0;
@@ -419,20 +419,20 @@
  * Find an existing ldap connection struct that matches the
  * provided ldap connection parameters.
  *
- * If not found in the cache, a new ldc structure will be allocated 
- * from st->pool and returned to the caller.  If found in the cache, 
+ * If not found in the cache, a new ldc structure will be allocated
+ * from st->pool and returned to the caller.  If found in the cache,
  * a pointer to the existing ldc structure will be returned.
  */
-static util_ldap_connection_t * 
+static util_ldap_connection_t *
             uldap_connection_find(request_rec *r,
                                   const char *host, int port,
                                   const char *binddn, const char *bindpw,
-                                  deref_options deref, int secure) 
+                                  deref_options deref, int secure)
 {
     struct util_ldap_connection_t *l, *p; /* To traverse the linked list */
     int secureflag = secure;
 
-    util_ldap_state_t *st = 
+    util_ldap_state_t *st =
         (util_ldap_state_t *)ap_get_module_config(r->server->module_config,
         &ldap_module);
 
@@ -440,7 +440,7 @@
 #if APR_HAS_THREADS
     /* mutex lock this function */
     if (!st->mutex) {
-        apr_thread_mutex_create(&st->mutex, APR_THREAD_MUTEX_DEFAULT, 
+        apr_thread_mutex_create(&st->mutex, APR_THREAD_MUTEX_DEFAULT,
                                 st->pool);
     }
     apr_thread_mutex_lock(st->mutex);
@@ -457,13 +457,13 @@
 #if APR_HAS_THREADS
         if (APR_SUCCESS == apr_thread_mutex_trylock(l->lock)) {
 #endif
-        if (   (l->port == port) && (strcmp(l->host, host) == 0) 
-            && ((!l->binddn && !binddn) || (l->binddn && binddn 
-                                             && !strcmp(l->binddn, binddn))) 
-            && ((!l->bindpw && !bindpw) || (l->bindpw && bindpw 
-                                             && !strcmp(l->bindpw, bindpw))) 
-            && (l->deref == deref) && (l->secure == secureflag) 
-            && !compare_client_certs(st->client_certs, l->client_certs)) 
+        if (   (l->port == port) && (strcmp(l->host, host) == 0)
+            && ((!l->binddn && !binddn) || (l->binddn && binddn
+                                             && !strcmp(l->binddn, binddn)))
+            && ((!l->bindpw && !bindpw) || (l->bindpw && bindpw
+                                             && !strcmp(l->bindpw, bindpw)))
+            && (l->deref == deref) && (l->secure == secureflag)
+            && !compare_client_certs(st->client_certs, l->client_certs))
         {
             break;
         }
@@ -486,9 +486,9 @@
             if (APR_SUCCESS == apr_thread_mutex_trylock(l->lock)) {
 
 #endif
-            if ((l->port == port) && (strcmp(l->host, host) == 0) && 
+            if ((l->port == port) && (strcmp(l->host, host) == 0) &&
                 (l->deref == deref) && (l->secure == secureflag) &&
-                !compare_client_certs(st->client_certs, l->client_certs)) 
+                !compare_client_certs(st->client_certs, l->client_certs))
             {
                 /* the bind credentials have changed */
                 l->bound = 0;
@@ -515,7 +515,7 @@
      */
     if (!l) {
 
-        /* 
+        /*
          * Add the new connection entry to the linked list. Note that we
          * don't actually establish an LDAP connection yet; that happens
          * the first time authentication is requested.
@@ -568,18 +568,18 @@
 /*
  * Compares two DNs to see if they're equal. The only way to do this correctly
  * is to search for the dn and then do ldap_get_dn() on the result. This should
- * match the initial dn, since it would have been also retrieved with 
- * ldap_get_dn(). This is expensive, so if the configuration value 
+ * match the initial dn, since it would have been also retrieved with
+ * ldap_get_dn(). This is expensive, so if the configuration value
  * compare_dn_on_server is false, just does an ordinary strcmp.
  *
  * The lock for the ldap cache should already be acquired.
  */
-static int uldap_cache_comparedn(request_rec *r, util_ldap_connection_t *ldc, 
-                                 const char *url, const char *dn, 
+static int uldap_cache_comparedn(request_rec *r, util_ldap_connection_t *ldc,
+                                 const char *url, const char *dn,
                                  const char *reqdn, int compare_dn_on_server)
 {
     int result = 0;
-    util_url_node_t *curl; 
+    util_url_node_t *curl;
     util_url_node_t curnode;
     util_dn_compare_node_t *node;
     util_dn_compare_node_t newnode;
@@ -588,7 +588,7 @@
     char *searchdn;
 
     util_ldap_state_t *st = (util_ldap_state_t *)
-                            ap_get_module_config(r->server->module_config, 
+                            ap_get_module_config(r->server->module_config,
                                                  &ldap_module);
 
     /* get cache entry (or create one) */
@@ -617,7 +617,7 @@
     if (curl) {
         /* no - it's a server side compare */
         LDAP_CACHE_LOCK();
-    
+
         /* is it in the compare cache? */
         newnode.reqdn = (char *)reqdn;
         node = util_ald_cache_fetch(curl->dn_compare_cache, &newnode);
@@ -628,7 +628,7 @@
             ldc->reason = "DN Comparison TRUE (cached)";
             return LDAP_COMPARE_TRUE;
         }
-    
+
         /* unlock this read lock */
         LDAP_CACHE_UNLOCK();
     }
@@ -647,9 +647,9 @@
 
     /* search for reqdn */
     if ((result = ldap_search_ext_s(ldc->ldap, (char *)reqdn, LDAP_SCOPE_BASE,
-                                    "(objectclass=*)", NULL, 1, 
-                                    NULL, NULL, NULL, -1, &res)) 
-            == LDAP_SERVER_DOWN) 
+                                    "(objectclass=*)", NULL, 1,
+                                    NULL, NULL, NULL, -1, &res))
+            == LDAP_SERVER_DOWN)
     {
         ldc->reason = "DN Comparison ldap_search_ext_s() "
                       "failed with server down";
@@ -677,11 +677,11 @@
             LDAP_CACHE_LOCK();
             newnode.reqdn = (char *)reqdn;
             newnode.dn = (char *)dn;
-            
+
             node = util_ald_cache_fetch(curl->dn_compare_cache, &newnode);
             if (   (node == NULL)
-                || (strcmp(reqdn, node->reqdn) != 0) 
-                || (strcmp(dn, node->dn) != 0)) 
+                || (strcmp(reqdn, node->reqdn) != 0)
+                || (strcmp(dn, node->dn) != 0))
             {
                 util_ald_cache_insert(curl->dn_compare_cache, &newnode);
             }
@@ -697,10 +697,10 @@
 
 /*
  * Does an generic ldap_compare operation. It accepts a cache that it will use
- * to lookup the compare in the cache. We cache two kinds of compares 
+ * to lookup the compare in the cache. We cache two kinds of compares
  * (require group compares) and (require user compares). Each compare has a different
  * cache node: require group includes the DN; require user does not because the
- * require user cache is owned by the 
+ * require user cache is owned by the
  *
  */
 static int uldap_cache_compare(request_rec *r, util_ldap_connection_t *ldc,
@@ -708,7 +708,7 @@
                                const char *attrib, const char *value)
 {
     int result = 0;
-    util_url_node_t *curl; 
+    util_url_node_t *curl;
     util_url_node_t curnode;
     util_compare_node_t *compare_nodep;
     util_compare_node_t the_compare_node;
@@ -732,15 +732,15 @@
         /* make a comparison to the cache */
         LDAP_CACHE_LOCK();
         curtime = apr_time_now();
-    
+
         the_compare_node.dn = (char *)dn;
         the_compare_node.attrib = (char *)attrib;
         the_compare_node.value = (char *)value;
         the_compare_node.result = 0;
-    
-        compare_nodep = util_ald_cache_fetch(curl->compare_cache, 
+
+        compare_nodep = util_ald_cache_fetch(curl->compare_cache,
                                              &the_compare_node);
-    
+
         if (compare_nodep != NULL) {
             /* found it... */
             if (curtime - compare_nodep->lastcompare > st->compare_cache_ttl) {
@@ -787,7 +787,7 @@
                                  (char *)dn,
                                  (char *)attrib,
                                  (char *)value))
-                                               == LDAP_SERVER_DOWN) { 
+                                               == LDAP_SERVER_DOWN) {
         /* connection failed - try again */
         ldc->reason = "ldap_compare_s() failed with server down";
         uldap_connection_unbind(ldc);
@@ -795,7 +795,7 @@
     }
 
     ldc->reason = "Comparison complete";
-    if ((LDAP_COMPARE_TRUE == result) || 
+    if ((LDAP_COMPARE_TRUE == result) ||
         (LDAP_COMPARE_FALSE == result) ||
         (LDAP_NO_SUCH_ATTRIBUTE == result)) {
         if (curl) {
@@ -805,13 +805,13 @@
             the_compare_node.result = result;
 
             /* If the node doesn't exist then insert it, otherwise just update
-             * it with the last results 
+             * it with the last results
              */
-            compare_nodep = util_ald_cache_fetch(curl->compare_cache, 
+            compare_nodep = util_ald_cache_fetch(curl->compare_cache,
                                                  &the_compare_node);
-            if (   (compare_nodep == NULL) 
-                || (strcmp(the_compare_node.dn, compare_nodep->dn) != 0) 
-                || (strcmp(the_compare_node.attrib,compare_nodep->attrib) != 0) 
+            if (   (compare_nodep == NULL)
+                || (strcmp(the_compare_node.dn, compare_nodep->dn) != 0)
+                || (strcmp(the_compare_node.attrib,compare_nodep->attrib) != 0)
                 || (strcmp(the_compare_node.value, compare_nodep->value) != 0))
             {
                 util_ald_cache_insert(curl->compare_cache, &the_compare_node);
@@ -839,9 +839,9 @@
 }
 
 static int uldap_cache_checkuserid(request_rec *r, util_ldap_connection_t *ldc,
-                                   const char *url, const char *basedn, 
+                                   const char *url, const char *basedn,
                                    int scope, char **attrs, const char *filter,
-                                   const char *bindpw, const char **binddn, 
+                                   const char *bindpw, const char **binddn,
                                    const char ***retvals)
 {
     const char **vals = NULL;
@@ -857,14 +857,14 @@
     util_search_node_t the_search_node;
     apr_time_t curtime;
 
-    util_ldap_state_t *st = 
+    util_ldap_state_t *st =
         (util_ldap_state_t *)ap_get_module_config(r->server->module_config,
         &ldap_module);
 
     /* Get the cache node for this url */
     LDAP_CACHE_LOCK();
     curnode.url = url;
-    curl = (util_url_node_t *)util_ald_cache_fetch(st->util_ldap_cache, 
+    curl = (util_url_node_t *)util_ald_cache_fetch(st->util_ldap_cache,
                                                    &curnode);
     if (curl == NULL) {
         curl = util_ald_create_caches(st, url);
@@ -874,26 +874,26 @@
     if (curl) {
         LDAP_CACHE_LOCK();
         the_search_node.username = filter;
-        search_nodep = util_ald_cache_fetch(curl->search_cache, 
+        search_nodep = util_ald_cache_fetch(curl->search_cache,
                                             &the_search_node);
         if (search_nodep != NULL) {
-    
+
             /* found entry in search cache... */
             curtime = apr_time_now();
-    
+
             /*
-             * Remove this item from the cache if its expired. If the sent 
-             * password doesn't match the storepassword, the entry will 
-             * be removed and readded later if the credentials pass 
+             * Remove this item from the cache if its expired. If the sent
+             * password doesn't match the storepassword, the entry will
+             * be removed and readded later if the credentials pass
              * authentication.
              */
             if ((curtime - search_nodep->lastbind) > st->search_cache_ttl) {
                 /* ...but entry is too old */
                 util_ald_cache_remove(curl->search_cache, search_nodep);
             }
-            else if (   (search_nodep->bindpw) 
-                     && (search_nodep->bindpw[0] != '\0') 
-                     && (strcmp(search_nodep->bindpw, bindpw) == 0)) 
+            else if (   (search_nodep->bindpw)
+                     && (search_nodep->bindpw[0] != '\0')
+                     && (strcmp(search_nodep->bindpw, bindpw) == 0))
             {
                 /* ...and entry is valid */
                 *binddn = search_nodep->dn;
@@ -907,7 +907,7 @@
         LDAP_CACHE_UNLOCK();
     }
 
-    /*	
+    /*
      * At this point, there is no valid cached search, so lets do the search.
      */
 
@@ -924,10 +924,10 @@
 
     /* try do the search */
     if ((result = ldap_search_ext_s(ldc->ldap,
-                                    (char *)basedn, scope, 
-                                    (char *)filter, attrs, 0, 
-                                    NULL, NULL, NULL, -1, &res)) 
-            == LDAP_SERVER_DOWN) 
+                                    (char *)basedn, scope,
+                                    (char *)filter, attrs, 0,
+                                    NULL, NULL, NULL, -1, &res))
+            == LDAP_SERVER_DOWN)
     {
         ldc->reason = "ldap_search_ext_s() for user failed with server down";
         uldap_connection_unbind(ldc);
@@ -940,12 +940,12 @@
         return result;
     }
 
-    /* 
+    /*
      * We should have found exactly one entry; to find a different
      * number is an error.
      */
     count = ldap_count_entries(ldc->ldap, res);
-    if (count != 1) 
+    if (count != 1)
     {
         if (count == 0 )
             ldc->reason = "User not found";
@@ -963,7 +963,7 @@
     *binddn = apr_pstrdup(r->pool, dn);
     ldap_memfree(dn);
 
-    /* 
+    /*
      * A bind to the server with an empty password always succeeds, so
      * we check to ensure that the password is not empty. This implies
      * that users who actually do have empty passwords will never be
@@ -976,7 +976,7 @@
         return LDAP_INVALID_CREDENTIALS;
     }
 
-    /* 
+    /*
      * Attempt to bind with the retrieved dn and the password. If the bind
      * fails, it means that the password is wrong (the dn obviously
      * exists, since we just retrieved it)
@@ -1024,7 +1024,7 @@
             /* get values */
             values = ldap_get_values(ldc->ldap, entry, attrs[i]);
             while (values && values[j]) {
-                str = str ? apr_pstrcat(r->pool, str, "; ", values[j], NULL) 
+                str = str ? apr_pstrcat(r->pool, str, "; ", values[j], NULL)
                           : apr_pstrdup(r->pool, values[j]);
                 j++;
             }
@@ -1035,7 +1035,7 @@
         *retvals = vals;
     }
 
-    /* 		
+    /*
      * Add the new username to the search cache.
      */
     if (curl) {
@@ -1047,13 +1047,13 @@
         the_search_node.vals = vals;
         the_search_node.numvals = numvals;
 
-        /* Search again to make sure that another thread didn't ready insert 
-         * this node into the cache before we got here. If it does exist then 
-         * update the lastbind 
+        /* Search again to make sure that another thread didn't ready insert
+         * this node into the cache before we got here. If it does exist then
+         * update the lastbind
          */
-        search_nodep = util_ald_cache_fetch(curl->search_cache, 
+        search_nodep = util_ald_cache_fetch(curl->search_cache,
                                             &the_search_node);
-        if ((search_nodep == NULL) || 
+        if ((search_nodep == NULL) ||
             (strcmp(*binddn, search_nodep->dn) != 0)) {
 
             /* Nothing in cache, insert new entry */
@@ -1086,8 +1086,8 @@
  * with password checking removed.
  */
 static int uldap_cache_getuserdn(request_rec *r, util_ldap_connection_t *ldc,
-                                 const char *url, const char *basedn, 
-                                 int scope, char **attrs, const char *filter, 
+                                 const char *url, const char *basedn,
+                                 int scope, char **attrs, const char *filter,
                                  const char **binddn, const char ***retvals)
 {
     const char **vals = NULL;
@@ -1103,14 +1103,14 @@
     util_search_node_t the_search_node;
     apr_time_t curtime;
 
-    util_ldap_state_t *st = 
+    util_ldap_state_t *st =
         (util_ldap_state_t *)ap_get_module_config(r->server->module_config,
         &ldap_module);
 
     /* Get the cache node for this url */
     LDAP_CACHE_LOCK();
     curnode.url = url;
-    curl = (util_url_node_t *)util_ald_cache_fetch(st->util_ldap_cache, 
+    curl = (util_url_node_t *)util_ald_cache_fetch(st->util_ldap_cache,
                                                    &curnode);
     if (curl == NULL) {
         curl = util_ald_create_caches(st, url);
@@ -1120,13 +1120,13 @@
     if (curl) {
         LDAP_CACHE_LOCK();
         the_search_node.username = filter;
-        search_nodep = util_ald_cache_fetch(curl->search_cache, 
+        search_nodep = util_ald_cache_fetch(curl->search_cache,
                                             &the_search_node);
         if (search_nodep != NULL) {
-    
+
             /* found entry in search cache... */
             curtime = apr_time_now();
-    
+
             /*
              * Remove this item from the cache if its expired.
              */
@@ -1147,7 +1147,7 @@
         LDAP_CACHE_UNLOCK();
     }
 
-    /*	
+    /*
      * At this point, there is no valid cached search, so lets do the search.
      */
 
@@ -1165,9 +1165,9 @@
     /* try do the search */
     if ((result = ldap_search_ext_s(ldc->ldap,
                                     (char *)basedn, scope,
-                                    (char *)filter, attrs, 0, 
-                                    NULL, NULL, NULL, -1, &res)) 
-            == LDAP_SERVER_DOWN) 
+                                    (char *)filter, attrs, 0,
+                                    NULL, NULL, NULL, -1, &res))
+            == LDAP_SERVER_DOWN)
     {
         ldc->reason = "ldap_search_ext_s() for user failed with server down";
         uldap_connection_unbind(ldc);
@@ -1180,12 +1180,12 @@
         return result;
     }
 
-    /* 
+    /*
      * We should have found exactly one entry; to find a different
      * number is an error.
      */
     count = ldap_count_entries(ldc->ldap, res);
-    if (count != 1) 
+    if (count != 1)
     {
         if (count == 0 )
             ldc->reason = "User not found";
@@ -1219,7 +1219,7 @@
             /* get values */
             values = ldap_get_values(ldc->ldap, entry, attrs[i]);
             while (values && values[j]) {
-                str = str ? apr_pstrcat(r->pool, str, "; ", values[j], NULL) 
+                str = str ? apr_pstrcat(r->pool, str, "; ", values[j], NULL)
                           : apr_pstrdup(r->pool, values[j]);
                 j++;
             }
@@ -1230,7 +1230,7 @@
         *retvals = vals;
     }
 
-    /* 		
+    /*
      * Add the new username to the search cache.
      */
     if (curl) {
@@ -1242,13 +1242,13 @@
         the_search_node.vals = vals;
         the_search_node.numvals = numvals;
 
-        /* Search again to make sure that another thread didn't ready insert 
-         * this node into the cache before we got here. If it does exist then 
-         * update the lastbind 
+        /* Search again to make sure that another thread didn't ready insert
+         * this node into the cache before we got here. If it does exist then
+         * update the lastbind
          */
         search_nodep = util_ald_cache_fetch(curl->search_cache,
                                             &the_search_node);
-        if ((search_nodep == NULL) || 
+        if ((search_nodep == NULL) ||
             (strcmp(*binddn, search_nodep->dn) != 0)) {
 
             /* Nothing in cache, insert new entry */
@@ -1273,7 +1273,7 @@
 }
 
 /*
- * Reports if ssl support is enabled 
+ * Reports if ssl support is enabled
  *
  * 1 = enabled, 0 = not enabled
  */
@@ -1290,28 +1290,28 @@
 /* config directives */
 
 
-static const char *util_ldap_set_cache_bytes(cmd_parms *cmd, void *dummy, 
+static const char *util_ldap_set_cache_bytes(cmd_parms *cmd, void *dummy,
                                              const char *bytes)
 {
-    util_ldap_state_t *st = 
-        (util_ldap_state_t *)ap_get_module_config(cmd->server->module_config, 
+    util_ldap_state_t *st =
+        (util_ldap_state_t *)ap_get_module_config(cmd->server->module_config,
                                                   &ldap_module);
 
     st->cache_bytes = atol(bytes);
 
-    ap_log_error(APLOG_MARK, APLOG_DEBUG, 0, cmd->server, 
+    ap_log_error(APLOG_MARK, APLOG_DEBUG, 0, cmd->server,
                  "[%" APR_PID_T_FMT "] ldap cache: Setting shared memory "
-                 " cache size to %" APR_SIZE_T_FMT " bytes.", 
+                 " cache size to %" APR_SIZE_T_FMT " bytes.",
                  getpid(), st->cache_bytes);
 
     return NULL;
 }
 
-static const char *util_ldap_set_cache_file(cmd_parms *cmd, void *dummy, 
+static const char *util_ldap_set_cache_file(cmd_parms *cmd, void *dummy,
                                             const char *file)
 {
-    util_ldap_state_t *st = 
-        (util_ldap_state_t *)ap_get_module_config(cmd->server->module_config, 
+    util_ldap_state_t *st =
+        (util_ldap_state_t *)ap_get_module_config(cmd->server->module_config,
                                                   &ldap_module);
 
     if (file) {
@@ -1321,34 +1321,34 @@
         st->cache_file = NULL;
     }
 
-    ap_log_error(APLOG_MARK, APLOG_DEBUG, 0, cmd->server, 
-                 "LDAP cache: Setting shared memory cache file to %s bytes.", 
+    ap_log_error(APLOG_MARK, APLOG_DEBUG, 0, cmd->server,
+                 "LDAP cache: Setting shared memory cache file to %s bytes.",
                  st->cache_file);
 
     return NULL;
 }
 
-static const char *util_ldap_set_cache_ttl(cmd_parms *cmd, void *dummy, 
+static const char *util_ldap_set_cache_ttl(cmd_parms *cmd, void *dummy,
                                            const char *ttl)
 {
-    util_ldap_state_t *st = 
-        (util_ldap_state_t *)ap_get_module_config(cmd->server->module_config, 
+    util_ldap_state_t *st =
+        (util_ldap_state_t *)ap_get_module_config(cmd->server->module_config,
                                                   &ldap_module);
 
     st->search_cache_ttl = atol(ttl) * 1000000;
 
-    ap_log_error(APLOG_MARK, APLOG_DEBUG, 0, cmd->server, 
+    ap_log_error(APLOG_MARK, APLOG_DEBUG, 0, cmd->server,
                  "[%" APR_PID_T_FMT "] ldap cache: Setting cache TTL to %ld microseconds.",
                  getpid(), st->search_cache_ttl);
 
     return NULL;
 }
 
-static const char *util_ldap_set_cache_entries(cmd_parms *cmd, void *dummy, 
+static const char *util_ldap_set_cache_entries(cmd_parms *cmd, void *dummy,
                                                const char *size)
 {
-    util_ldap_state_t *st = 
-        (util_ldap_state_t *)ap_get_module_config(cmd->server->module_config, 
+    util_ldap_state_t *st =
+        (util_ldap_state_t *)ap_get_module_config(cmd->server->module_config,
                                                   &ldap_module);
 
 
@@ -1357,34 +1357,34 @@
         st->search_cache_size = 0;
     }
 
-    ap_log_error(APLOG_MARK, APLOG_DEBUG, 0, cmd->server, 
+    ap_log_error(APLOG_MARK, APLOG_DEBUG, 0, cmd->server,
                  "[%" APR_PID_T_FMT "] ldap cache: Setting search cache size to %ld entries.",
                  getpid(), st->search_cache_size);
 
     return NULL;
 }
 
-static const char *util_ldap_set_opcache_ttl(cmd_parms *cmd, void *dummy, 
+static const char *util_ldap_set_opcache_ttl(cmd_parms *cmd, void *dummy,
                                              const char *ttl)
 {
-    util_ldap_state_t *st = 
-        (util_ldap_state_t *)ap_get_module_config(cmd->server->module_config, 
+    util_ldap_state_t *st =
+        (util_ldap_state_t *)ap_get_module_config(cmd->server->module_config,
                                                   &ldap_module);
 
     st->compare_cache_ttl = atol(ttl) * 1000000;
 
-    ap_log_error(APLOG_MARK, APLOG_DEBUG, 0, cmd->server, 
-                 "[%" APR_PID_T_FMT "] ldap cache: Setting operation cache TTL to %ld microseconds.", 
+    ap_log_error(APLOG_MARK, APLOG_DEBUG, 0, cmd->server,
+                 "[%" APR_PID_T_FMT "] ldap cache: Setting operation cache TTL to %ld microseconds.",
                  getpid(), st->compare_cache_ttl);
 
     return NULL;
 }
 
-static const char *util_ldap_set_opcache_entries(cmd_parms *cmd, void *dummy, 
+static const char *util_ldap_set_opcache_entries(cmd_parms *cmd, void *dummy,
                                                  const char *size)
 {
-    util_ldap_state_t *st = 
-        (util_ldap_state_t *)ap_get_module_config(cmd->server->module_config, 
+    util_ldap_state_t *st =
+        (util_ldap_state_t *)ap_get_module_config(cmd->server->module_config,
                                                   &ldap_module);
 
     st->compare_cache_size = atol(size);
@@ -1392,7 +1392,7 @@
         st->compare_cache_size = 0;
     }
 
-    ap_log_error(APLOG_MARK, APLOG_DEBUG, 0, cmd->server, 
+    ap_log_error(APLOG_MARK, APLOG_DEBUG, 0, cmd->server,
                  "[%" APR_PID_T_FMT "] ldap cache: Setting operation cache size to %ld "
                  "entries.", getpid(), st->compare_cache_size);
 
@@ -1488,10 +1488,10 @@
  *
  * This directive may only be used globally.
  */
-static const char *util_ldap_set_trusted_global_cert(cmd_parms *cmd, 
-                                                     void *dummy, 
-                                                     const char *type, 
-                                                     const char *file, 
+static const char *util_ldap_set_trusted_global_cert(cmd_parms *cmd,
+                                                     void *dummy,
+                                                     const char *type,
+                                                     const char *file,
                                                      const char *password)
 {
     util_ldap_state_t *st =
@@ -1539,8 +1539,8 @@
 
         cert->path = ap_server_root_relative(cmd->pool, file);
         if (cert->path &&
-            ((rv = apr_stat (&finfo, cert->path, APR_FINFO_MIN, cmd->pool)) 
-                != APR_SUCCESS)) 
+            ((rv = apr_stat (&finfo, cert->path, APR_FINFO_MIN, cmd->pool))
+                != APR_SUCCESS))
         {
             ap_log_error(APLOG_MARK, APLOG_ERR, rv, cmd->server,
                          "LDAP: Could not open SSL trusted certificate "
@@ -1562,10 +1562,10 @@
  * - certificate file / directory / nickname
  * - certificate password (optional)
  */
-static const char *util_ldap_set_trusted_client_cert(cmd_parms *cmd, 
-                                                     void *config, 
-                                                     const char *type, 
-                                                     const char *file, 
+static const char *util_ldap_set_trusted_client_cert(cmd_parms *cmd,
+                                                     void *config,
+                                                     const char *type,
+                                                     const char *file,
                                                      const char *password)
 {
     util_ldap_state_t *st =
@@ -1584,7 +1584,7 @@
                                            "not recognised. It should be one "
                                            "of CERT_DER, CERT_BASE64, "
                                            "CERT_NICKNAME, CERT_PFX,"
-                                           "KEY_DER, KEY_BASE64, KEY_PFX", 
+                                           "KEY_DER, KEY_BASE64, KEY_PFX",
                                            type);
         }
         else if (APR_LDAP_CA_TYPE_DER == cert_type ||
@@ -1611,7 +1611,7 @@
 
     /* add the certificate to the global array */
     cert = (apr_ldap_opt_tls_cert_t *)apr_array_push(st->global_certs);
-    cert->type = cert_type; 
+    cert->type = cert_type;
     cert->path = file;
     cert->password = password;
 
@@ -1621,8 +1621,8 @@
 
         cert->path = ap_server_root_relative(cmd->pool, file);
         if (cert->path &&
-            ((rv = apr_stat (&finfo, cert->path, APR_FINFO_MIN, cmd->pool)) 
-                != APR_SUCCESS)) 
+            ((rv = apr_stat (&finfo, cert->path, APR_FINFO_MIN, cmd->pool))
+                != APR_SUCCESS))
         {
             ap_log_error(APLOG_MARK, APLOG_ERR, rv, cmd->server,
                          "LDAP: Could not open SSL client certificate "
@@ -1639,13 +1639,13 @@
 
 /**
  * Set LDAPTrustedMode.
- *                    
+ *
  * This directive sets what encryption mode to use on a connection:
  * - None (No encryption)
  * - SSL (SSL encryption)
  * - STARTTLS (TLS encryption)
- */ 
-static const char *util_ldap_set_trusted_mode(cmd_parms *cmd, void *dummy, 
+ */
+static const char *util_ldap_set_trusted_mode(cmd_parms *cmd, void *dummy,
                                               const char *mode)
 {
     util_ldap_state_t *st =
@@ -1675,8 +1675,8 @@
     return(NULL);
 }
 
-static const char *util_ldap_set_verify_srv_cert(cmd_parms *cmd, 
-                                                 void *dummy, 
+static const char *util_ldap_set_verify_srv_cert(cmd_parms *cmd,
+                                                 void *dummy,
                                                  int mode)
 {
     util_ldap_state_t *st =
@@ -1684,7 +1684,7 @@
                                               &ldap_module);
 
     ap_log_error(APLOG_MARK, APLOG_DEBUG, 0, cmd->server,
-                      "LDAP: SSL verify server certificate - %s", 
+                      "LDAP: SSL verify server certificate - %s",
                       mode?"TRUE":"FALSE");
 
     st->verify_svr_cert = mode;
@@ -1693,12 +1693,12 @@
 }
 
 
-static const char *util_ldap_set_connection_timeout(cmd_parms *cmd, 
-                                                    void *dummy, 
+static const char *util_ldap_set_connection_timeout(cmd_parms *cmd,
+                                                    void *dummy,
                                                     const char *ttl)
 {
-    util_ldap_state_t *st = 
-        (util_ldap_state_t *)ap_get_module_config(cmd->server->module_config, 
+    util_ldap_state_t *st =
+        (util_ldap_state_t *)ap_get_module_config(cmd->server->module_config,
                                                   &ldap_module);
     const char *err = ap_check_cmd_context(cmd, GLOBAL_ONLY);
 
@@ -1709,7 +1709,7 @@
 #ifdef LDAP_OPT_NETWORK_TIMEOUT
     st->connectionTimeout = atol(ttl);
 
-    ap_log_error(APLOG_MARK, APLOG_DEBUG, 0, cmd->server, 
+    ap_log_error(APLOG_MARK, APLOG_DEBUG, 0, cmd->server,
                  "[%" APR_PID_T_FMT "] ldap connection: Setting connection timeout to "
                  "%ld seconds.", getpid(), st->connectionTimeout);
 #else
@@ -1724,7 +1724,7 @@
 
 static void *util_ldap_create_config(apr_pool_t *p, server_rec *s)
 {
-    util_ldap_state_t *st = 
+    util_ldap_state_t *st =
         (util_ldap_state_t *)apr_pcalloc(p, sizeof(util_ldap_state_t));
 
     st->pool = p;
@@ -1746,7 +1746,7 @@
     return st;
 }
 
-static void *util_ldap_merge_config(apr_pool_t *p, void *basev, 
+static void *util_ldap_merge_config(apr_pool_t *p, void *basev,
                                     void *overridesv)
 {
     util_ldap_state_t *st = apr_pcalloc(p, sizeof(util_ldap_state_t));
@@ -1762,11 +1762,11 @@
     st->compare_cache_size = base->compare_cache_size;
     st->connections = base->connections;
     st->ssl_supported = base->ssl_supported;
-    st->global_certs = apr_array_append(p, base->global_certs, 
+    st->global_certs = apr_array_append(p, base->global_certs,
                                            overrides->global_certs);
-    st->client_certs = apr_array_append(p, base->client_certs, 
+    st->client_certs = apr_array_append(p, base->client_certs,
                                            overrides->client_certs);
-    st->secure = (overrides->secure_set == 0) ? base->secure 
+    st->secure = (overrides->secure_set == 0) ? base->secure
                                               : overrides->secure;
 
     return st;
@@ -1778,7 +1778,7 @@
     server_rec *s = data;
     util_ldap_state_t *st = (util_ldap_state_t *)ap_get_module_config(
         s->module_config, &ldap_module);
-    
+
     if (st->ssl_supported) {
         apr_ldap_ssl_deinit();
     }
@@ -1787,7 +1787,7 @@
 
 }
 
-static int util_ldap_post_config(apr_pool_t *p, apr_pool_t *plog, 
+static int util_ldap_post_config(apr_pool_t *p, apr_pool_t *plog,
                                  apr_pool_t *ptemp, server_rec *s)
 {
     apr_status_t result;
@@ -1795,7 +1795,7 @@
     util_ldap_state_t *st_vhost;
 
     util_ldap_state_t *st = (util_ldap_state_t *)
-                            ap_get_module_config(s->module_config, 
+                            ap_get_module_config(s->module_config,
                                                  &ldap_module);
 
     void *data;
@@ -1815,7 +1815,7 @@
         /* If the cache file already exists then delete it.  Otherwise we are
          * going to run into problems creating the shared memory. */
         if (st->cache_file) {
-            char *lck_file = apr_pstrcat(st->pool, st->cache_file, ".lck", 
+            char *lck_file = apr_pstrcat(st->pool, st->cache_file, ".lck",
                                          NULL);
             apr_file_remove(lck_file, ptemp);
         }
@@ -1824,8 +1824,8 @@
     }
 
 #if APR_HAS_SHARED_MEMORY
-    /* initializing cache if shared memory size is not zero and we already 
-     * don't have shm address 
+    /* initializing cache if shared memory size is not zero and we already
+     * don't have shm address
      */
     if (!st->cache_shm && st->cache_bytes > 0) {
 #endif
@@ -1839,13 +1839,13 @@
 
 #if APR_HAS_SHARED_MEMORY
         if (st->cache_file) {
-            st->lock_file = apr_pstrcat(st->pool, st->cache_file, ".lck", 
+            st->lock_file = apr_pstrcat(st->pool, st->cache_file, ".lck",
                                         NULL);
         }
 #endif
 
-        result = apr_global_mutex_create(&st->util_ldap_cache_lock, 
-                                         st->lock_file, APR_LOCK_DEFAULT, 
+        result = apr_global_mutex_create(&st->util_ldap_cache_lock,
+                                         st->lock_file, APR_LOCK_DEFAULT,
                                          st->pool);
         if (result != APR_SUCCESS) {
             return result;
@@ -1854,7 +1854,7 @@
 #ifdef AP_NEED_SET_MUTEX_PERMS
         result = unixd_set_global_mutex_perms(st->util_ldap_cache_lock);
         if (result != APR_SUCCESS) {
-            ap_log_error(APLOG_MARK, APLOG_CRIT, result, s, 
+            ap_log_error(APLOG_MARK, APLOG_CRIT, result, s,
                          "LDAP cache: failed to set mutex permissions");
             return result;
         }
@@ -1864,16 +1864,16 @@
         s_vhost = s->next;
         while (s_vhost) {
             st_vhost = (util_ldap_state_t *)
-                       ap_get_module_config(s_vhost->module_config, 
+                       ap_get_module_config(s_vhost->module_config,
                                             &ldap_module);
 
 #if APR_HAS_SHARED_MEMORY
             st_vhost->cache_shm = st->cache_shm;
             st_vhost->cache_rmm = st->cache_rmm;
             st_vhost->cache_file = st->cache_file;
-            ap_log_error(APLOG_MARK, APLOG_DEBUG, result, s, 
+            ap_log_error(APLOG_MARK, APLOG_DEBUG, result, s,
                          "LDAP merging Shared Cache conf: shm=0x%pp rmm=0x%pp "
-                         "for VHOST: %s", st->cache_shm, st->cache_rmm, 
+                         "for VHOST: %s", st->cache_shm, st->cache_rmm,
                          s_vhost->server_hostname);
 #endif
             st_vhost->lock_file = st->lock_file;
@@ -1882,13 +1882,13 @@
 #if APR_HAS_SHARED_MEMORY
     }
     else {
-        ap_log_error(APLOG_MARK, APLOG_DEBUG, 0, s, 
+        ap_log_error(APLOG_MARK, APLOG_DEBUG, 0, s,
                      "LDAP cache: LDAPSharedCacheSize is zero, disabling "
                      "shared memory cache");
     }
 #endif
-    
-    /* log the LDAP SDK used 
+
+    /* log the LDAP SDK used
      */
     {
         apr_ldap_err_t *result = NULL;
@@ -1899,7 +1899,7 @@
     }
 
     apr_pool_cleanup_register(p, s, util_ldap_cleanup_module,
-                              util_ldap_cleanup_module); 
+                              util_ldap_cleanup_module);
 
     /*
      * Initialize SSL support, and log the result for the benefit of the admin.
@@ -1907,9 +1907,9 @@
      * If SSL is not supported it is not necessarily an error, as the
      * application may not want to use it.
      */
-    rc = apr_ldap_ssl_init(p, 
-                      NULL, 
-                      0, 
+    rc = apr_ldap_ssl_init(p,
+                      NULL,
+                      0,
                       &(result_err));
     if (APR_SUCCESS == rc) {
         rc = apr_ldap_set_option(p, NULL, APR_LDAP_OPT_TLS_CERT,
@@ -1923,7 +1923,7 @@
     }
     else {
         st->ssl_supported = 0;
-        ap_log_error(APLOG_MARK, APLOG_INFO, 0, s, 
+        ap_log_error(APLOG_MARK, APLOG_INFO, 0, s,
                      "LDAP: SSL support unavailable%s%s",
                      result_err ? ": " : "",
                      result_err ? result_err->reason : "");
@@ -1935,12 +1935,12 @@
 static void util_ldap_child_init(apr_pool_t *p, server_rec *s)
 {
     apr_status_t sts;
-    util_ldap_state_t *st = ap_get_module_config(s->module_config, 
+    util_ldap_state_t *st = ap_get_module_config(s->module_config,
                                                  &ldap_module);
 
     if (!st->util_ldap_cache_lock) return;
 
-    sts = apr_global_mutex_child_init(&st->util_ldap_cache_lock, 
+    sts = apr_global_mutex_child_init(&st->util_ldap_cache_lock,
                                       st->lock_file, p);
     if (sts != APR_SUCCESS) {
         ap_log_error(APLOG_MARK, APLOG_CRIT, sts, s,
@@ -1951,34 +1951,34 @@
 }
 
 static const command_rec util_ldap_cmds[] = {
-    AP_INIT_TAKE1("LDAPSharedCacheSize", util_ldap_set_cache_bytes, 
+    AP_INIT_TAKE1("LDAPSharedCacheSize", util_ldap_set_cache_bytes,
                   NULL, RSRC_CONF,
                   "Set the size of the shared memory cache (in bytes). Use "
                   "0 to disable the shared memory cache. (default: 100000)"),
 
-    AP_INIT_TAKE1("LDAPSharedCacheFile", util_ldap_set_cache_file, 
+    AP_INIT_TAKE1("LDAPSharedCacheFile", util_ldap_set_cache_file,
                   NULL, RSRC_CONF,
                   "Set the file name for the shared memory cache."),
 
-    AP_INIT_TAKE1("LDAPCacheEntries", util_ldap_set_cache_entries, 
+    AP_INIT_TAKE1("LDAPCacheEntries", util_ldap_set_cache_entries,
                   NULL, RSRC_CONF,
                   "Set the maximum number of entries that are possible in the "
                   "LDAP search cache. Use 0 for no limit. "
                   "-1 disables the cache. (default: 1024)"),
 
-    AP_INIT_TAKE1("LDAPCacheTTL", util_ldap_set_cache_ttl, 
+    AP_INIT_TAKE1("LDAPCacheTTL", util_ldap_set_cache_ttl,
                   NULL, RSRC_CONF,
                   "Set the maximum time (in seconds) that an item can be "
                   "cached in the LDAP search cache. Use 0 for no limit. "
                   "(default 600)"),
 
-    AP_INIT_TAKE1("LDAPOpCacheEntries", util_ldap_set_opcache_entries, 
+    AP_INIT_TAKE1("LDAPOpCacheEntries", util_ldap_set_opcache_entries,
                   NULL, RSRC_CONF,
                   "Set the maximum number of entries that are possible "
                   "in the LDAP compare cache. Use 0 for no limit. "
                   "Use -1 to disable the cache. (default: 1024)"),
 
-    AP_INIT_TAKE1("LDAPOpCacheTTL", util_ldap_set_opcache_ttl, 
+    AP_INIT_TAKE1("LDAPOpCacheTTL", util_ldap_set_opcache_ttl,
                   NULL, RSRC_CONF,
                   "Set the maximum time (in seconds) that an item is cached "
                   "in the LDAP operation cache. Use 0 for no limit. "
@@ -2004,17 +2004,17 @@
                    "CERT_NICKNAME, KEY_DER, or KEY_BASE64. Third arg is an "
                    "optional passphrase if applicable."),
 
-    AP_INIT_TAKE1("LDAPTrustedMode", util_ldap_set_trusted_mode, 
+    AP_INIT_TAKE1("LDAPTrustedMode", util_ldap_set_trusted_mode,
                   NULL, RSRC_CONF,
                   "Specify the type of security that should be applied to "
                   "an LDAP connection. One of; NONE, SSL or STARTTLS."),
 
-    AP_INIT_FLAG("LDAPVerifyServerCert", util_ldap_set_verify_srv_cert, 
+    AP_INIT_FLAG("LDAPVerifyServerCert", util_ldap_set_verify_srv_cert,
                   NULL, RSRC_CONF,
                   "Set to 'ON' requires that the server certificate be verified "
                   "before a secure LDAP connection can be establish.  Default 'ON'"),
 
-    AP_INIT_TAKE1("LDAPConnectionTimeout", util_ldap_set_connection_timeout, 
+    AP_INIT_TAKE1("LDAPConnectionTimeout", util_ldap_set_connection_timeout,
                   NULL, RSRC_CONF,
                   "Specify the LDAP socket connection timeout in seconds "
                   "(default: 10)"),

Modified: httpd/httpd/trunk/modules/ldap/util_ldap_cache.c
URL: http://svn.apache.org/viewcvs/httpd/httpd/trunk/modules/ldap/util_ldap_cache.c?rev=332306&r1=332305&r2=332306&view=diff
==============================================================================
--- httpd/httpd/trunk/modules/ldap/util_ldap_cache.c (original)
+++ httpd/httpd/trunk/modules/ldap/util_ldap_cache.c Thu Nov 10 07:11:44 2005
@@ -16,9 +16,9 @@
 
 /*
  * util_ldap_cache.c: LDAP cache things
- * 
+ *
  * Original code from auth_ldap module for Apache v1.3:
- * Copyright 1998, 1999 Enbridge Pipelines Inc. 
+ * Copyright 1998, 1999 Enbridge Pipelines Inc.
  * Copyright 1999-2001 Dave Carrigan
  */
 
@@ -100,14 +100,14 @@
                 type_str = "DN Compares";
                 break;
         }
-        
+
         if (cache_node->marktime) {
             apr_ctime(date_str, cache_node->marktime);
         }
-        else 
+        else
             date_str[0] = 0;
 
-        ap_rprintf(r, 
+        ap_rprintf(r,
                    "<tr valign='top'>"
                    "<td nowrap>%s (%s)</td>"
                    "<td nowrap>%ld</td>"
@@ -299,7 +299,7 @@
         cmp_result = apr_itoa(r->pool, node->result);
     }
 
-    ap_rprintf(r, 
+    ap_rprintf(r,
                "<tr valign='top'>"
                "<td nowrap>%s</td>"
                "<td nowrap>%s</td>"
@@ -360,7 +360,7 @@
 {
     util_dn_compare_node_t *node = n;
 
-    ap_rprintf(r, 
+    ap_rprintf(r,
                "<tr valign='top'>"
                "<td nowrap>%s</td>"
                "<td nowrap>%s</td>"
@@ -412,8 +412,8 @@
     size = apr_shm_size_get(st->cache_shm);
 
     /* This will create a rmm "handler" to get into the shared memory area */
-    result = apr_rmm_init(&st->cache_rmm, NULL, 
-                          apr_shm_baseaddr_get(st->cache_shm), size, 
+    result = apr_rmm_init(&st->cache_rmm, NULL,
+                          apr_shm_baseaddr_get(st->cache_shm), size,
                           st->pool);
     if (result != APR_SUCCESS) {
         return result;

Modified: httpd/httpd/trunk/modules/ldap/util_ldap_cache_mgr.c
URL: http://svn.apache.org/viewcvs/httpd/httpd/trunk/modules/ldap/util_ldap_cache_mgr.c?rev=332306&r1=332305&r2=332306&view=diff
==============================================================================
--- httpd/httpd/trunk/modules/ldap/util_ldap_cache_mgr.c (original)
+++ httpd/httpd/trunk/modules/ldap/util_ldap_cache_mgr.c Thu Nov 10 07:11:44 2005
@@ -16,9 +16,9 @@
 
 /*
  * util_ldap_cache_mgr.c: LDAP cache manager things
- * 
+ *
  * Original code from auth_ldap module for Apache v1.3:
- * Copyright 1998, 1999 Enbridge Pipelines Inc. 
+ * Copyright 1998, 1999 Enbridge Pipelines Inc.
  * Copyright 1999-2001 Dave Carrigan
  */
 
@@ -138,7 +138,7 @@
 
 /*
  * Computes the hash on a set of strings. The first argument is the number
- * of strings to hash, the rest of the args are strings. 
+ * of strings to hash, the rest of the args are strings.
  * Algorithm taken from glibc.
  */
 unsigned long util_ald_hash_string(int nstr, ...)
@@ -147,7 +147,7 @@
     va_list args;
     unsigned long h=0, g;
     char *str, *p;
-  
+
     va_start(args, nstr);
     for (i=0; i < nstr; ++i) {
         str = va_arg(args, char *);
@@ -204,8 +204,8 @@
     }
 
     t = apr_time_now();
-    cache->avg_purgetime = 
-         ((t - cache->last_purge) + (cache->avg_purgetime * (cache->numpurges-1))) / 
+    cache->avg_purgetime =
+         ((t - cache->last_purge) + (cache->avg_purgetime * (cache->numpurges-1))) /
          cache->numpurges;
 }
 
@@ -265,7 +265,7 @@
 
 util_ald_cache_t *util_ald_create_cache(util_ldap_state_t *st,
                                 long cache_size,
-                                unsigned long (*hashfunc)(void *), 
+                                unsigned long (*hashfunc)(void *),
                                 int (*comparefunc)(void *, void *),
                                 void * (*copyfunc)(util_ald_cache_t *cache, void *),
                                 void (*freefunc)(util_ald_cache_t *cache, void *),
@@ -365,7 +365,7 @@
     cache->fetches++;
 
     hashval = (*cache->hash)(payload) % cache->size;
-    for (p = cache->nodes[hashval]; 
+    for (p = cache->nodes[hashval];
          p && !(*cache->compare)(p->payload, payload);
     p = p->next) ;
 
@@ -379,7 +379,7 @@
 }
 
 /*
- * Insert an item into the cache. 
+ * Insert an item into the cache.
  * *** Does not catch duplicates!!! ***
  */
 void *util_ald_cache_insert(util_ald_cache_t *cache, void *payload)
@@ -435,7 +435,7 @@
 {
     unsigned long hashval;
     util_cache_node_t *p, *q;
-  
+
     if (cache == NULL)
         return;
 
@@ -491,7 +491,7 @@
     chainlen = nchains? (double)totchainlen / (double)nchains : 0;
 
     if (id) {
-        buf2 = apr_psprintf(p, 
+        buf2 = apr_psprintf(p,
                  "<a href=\"%s?%s\">%s</a>",
              r->uri,
              id,
@@ -501,7 +501,7 @@
         buf2 = name;
     }
 
-    buf = apr_psprintf(p, 
+    buf = apr_psprintf(p,
              "<tr valign='top'>"
              "<td nowrap>%s</td>"
              "<td align='right' nowrap>%lu (%.0f%% full)</td>"
@@ -510,7 +510,7 @@
              "<td align='right'>%.0f%%</td>"
              "<td align='right'>%lu/%lu</td>",
          buf2,
-         cache->numentries, 
+         cache->numentries,
          (double)cache->numentries / (double)cache->maxentries * 100.0,
          chainlen,
          cache->hits,
@@ -526,13 +526,13 @@
         buf = apr_psprintf(p,
                  "%s"
                  "<td align='right'>%lu</td>\n"
-                 "<td align='right' nowrap>%s</td>\n", 
+                 "<td align='right' nowrap>%s</td>\n",
              buf,
              cache->numpurges,
              str_ctime);
     }
     else {
-        buf = apr_psprintf(p, 
+        buf = apr_psprintf(p,
                  "%s<td colspan='2' align='center'>(none)</td>\n",
              buf);
     }
@@ -585,10 +585,10 @@
                        "</tr>\n"
                        "</table>\n</p>\n",
                        buf,
-                       cachetype[0] == 'm'? "Main" : 
-                       (cachetype[0] == 's' ? "Search" : 
+                       cachetype[0] == 'm'? "Main" :
+                       (cachetype[0] == 's' ? "Search" :
                         (cachetype[0] == 'c' ? "Compares" : "DNCompares")));
-            
+
             switch (cachetype[0]) {
                 case 'm':
                     if (util_ldap_cache->marktime) {
@@ -645,7 +645,7 @@
                         }
                     }
                     ap_rputs("</table>\n</p>\n", r);
-                    
+
 
                     break;
                 case 's':
@@ -660,7 +660,7 @@
                     if (n) {
                         for (i=0; i < n->search_cache->size; ++i) {
                             for (p = n->search_cache->nodes[i]; p != NULL; p = p->next) {
-    
+
                                 (*n->search_cache->display)(r, n->search_cache, p->payload);
                             }
                         }
@@ -681,7 +681,7 @@
                     if (n) {
                         for (i=0; i < n->compare_cache->size; ++i) {
                             for (p = n->compare_cache->nodes[i]; p != NULL; p = p->next) {
-    
+
                                 (*n->compare_cache->display)(r, n->compare_cache, p->payload);
                             }
                         }
@@ -699,7 +699,7 @@
                     if (n) {
                         for (i=0; i < n->dn_compare_cache->size; ++i) {
                             for (p = n->dn_compare_cache->nodes[i]; p != NULL; p = p->next) {
-    
+
                                 (*n->dn_compare_cache->display)(r, n->dn_compare_cache, p->payload);
                             }
                         }
@@ -732,19 +732,19 @@
 
         id1 = apr_psprintf(pool, argfmt, "main", 0, 0);
         buf = util_ald_cache_display_stats(r, st->util_ldap_cache, "LDAP URL Cache", id1);
-    
+
         for (i=0; i < util_ldap_cache->size; ++i) {
             for (p = util_ldap_cache->nodes[i],j=0; p != NULL; p = p->next,j++) {
-    
+
                 n = (util_url_node_t *)p->payload;
-    
+
                 t1 = apr_psprintf(pool, "%s (Searches)", n->url);
                 t2 = apr_psprintf(pool, "%s (Compares)", n->url);
                 t3 = apr_psprintf(pool, "%s (DNCompares)", n->url);
                 id1 = apr_psprintf(pool, argfmt, "srch", i, j);
                 id2 = apr_psprintf(pool, argfmt, "cmpr", i, j);
                 id3 = apr_psprintf(pool, argfmt, "dncp", i, j);
-    
+
                 buf = apr_psprintf(pool, "%s\n\n"
                                          "%s\n\n"
                                          "%s\n\n"

Modified: httpd/httpd/trunk/modules/loggers/mod_log_config.c
URL: http://svn.apache.org/viewcvs/httpd/httpd/trunk/modules/loggers/mod_log_config.c?rev=332306&r1=332305&r2=332306&view=diff
==============================================================================
--- httpd/httpd/trunk/modules/loggers/mod_log_config.c (original)
+++ httpd/httpd/trunk/modules/loggers/mod_log_config.c Thu Nov 10 07:11:44 2005
@@ -45,7 +45,7 @@
  * the VirtualHost will _not_ be used. This makes this module compatable
  * with the CLF and config log modules, where the use of TransferLog
  * inside the VirtualHost section overrides its use outside.
- * 
+ *
  * Examples:
  *
  *    TransferLog    logs/access_log
@@ -176,20 +176,20 @@
 static apr_fileperms_t xfer_perms = APR_OS_DEFAULT;
 static apr_hash_t *log_hash;
 static apr_status_t ap_default_log_writer(request_rec *r,
-                           void *handle, 
+                           void *handle,
                            const char **strs,
                            int *strl,
                            int nelts,
                            apr_size_t len);
 static apr_status_t ap_buffered_log_writer(request_rec *r,
-                           void *handle, 
+                           void *handle,
                            const char **strs,
                            int *strl,
                            int nelts,
                            apr_size_t len);
-static void *ap_default_log_writer_init(apr_pool_t *p, server_rec *s, 
+static void *ap_default_log_writer_init(apr_pool_t *p, server_rec *s,
                                         const char* name);
-static void *ap_buffered_log_writer_init(apr_pool_t *p, server_rec *s, 
+static void *ap_buffered_log_writer_init(apr_pool_t *p, server_rec *s,
                                         const char* name);
 
 static ap_log_writer_init* ap_log_set_writer_init(ap_log_writer_init *handle);
@@ -242,10 +242,10 @@
  * be NULL, which means this module does no logging for this
  * request. format might be NULL, in which case the default_format
  * from the multi_log_state should be used, or if that is NULL as
- * well, use the CLF. 
+ * well, use the CLF.
  * log_writer is NULL before the log file is opened and is
  * set to a opaque structure (usually a fd) after it is opened.
- 
+
  */
 typedef struct {
     apr_file_t *handle;
@@ -507,7 +507,7 @@
             start_cookie += strlen(a) + 1; /* cookie_name + '=' */
             cookie = apr_pstrdup(r->pool, start_cookie);
             /* kill everything in cookie after ';' */
-            end_cookie = strchr(cookie, ';'); 
+            end_cookie = strchr(cookie, ';');
             if (end_cookie) {
                 *end_cookie = '\0';
             }
@@ -619,7 +619,7 @@
 
 static const char *log_request_duration_microseconds(request_rec *r, char *a)
 {
-    return apr_psprintf(r->pool, "%" APR_TIME_T_FMT, 
+    return apr_psprintf(r->pool, "%" APR_TIME_T_FMT,
                         (apr_time_now() - r->request_time));
 }
 
@@ -675,7 +675,7 @@
     if (r->connection->aborted)
         return "X";
 
-    if (r->connection->keepalive == AP_CONN_KEEPALIVE && 
+    if (r->connection->keepalive == AP_CONN_KEEPALIVE &&
         (!r->server->keep_alive_max ||
          (r->server->keep_alive_max - r->connection->keepalives) > 0)) {
         return "+";
@@ -767,7 +767,7 @@
         it->arg = "%";
         it->func = constant_item;
         *sa = ++s;
-    
+
         return NULL;
     }
 
@@ -1153,10 +1153,10 @@
     if (cls->fname == NULL) {
         return cls;             /* Leave it NULL to decline.  */
     }
-    
+
     cls->log_writer = log_writer_init(p, s, cls->fname);
     if (cls->log_writer == NULL)
-        return NULL; 
+        return NULL;
 
     return cls;
 }
@@ -1175,7 +1175,7 @@
         if (format) {
             mls->default_format = parse_log_string(p, format, &dummy);
         }
-    }    
+    }
 
     if (!mls->default_format) {
         mls->default_format = parse_log_string(p, DEFAULT_LOG_FORMAT, &dummy);
@@ -1233,7 +1233,7 @@
 
     if (!buffered_logs)
         return APR_SUCCESS;
-    
+
     for (; s; s = s->next) {
         mls = ap_get_module_config(s->module_config, &log_config_module);
         log_list = NULL;
@@ -1288,12 +1288,12 @@
     if (buffered_logs) {
         int i;
         buffered_log **array = (buffered_log **)all_buffered_logs->elts;
-        
+
         apr_pool_cleanup_register(p, s, flush_all_logs, flush_all_logs);
 
         for (i = 0; i < all_buffered_logs->nelts; i++) {
             buffered_log *this = array[i];
-            
+
 #if APR_HAS_THREADS
             if (mpm_threads > 1) {
                 apr_status_t rv;
@@ -1318,7 +1318,7 @@
     }
 }
 
-static void ap_register_log_handler(apr_pool_t *p, char *tag, 
+static void ap_register_log_handler(apr_pool_t *p, char *tag,
                                     ap_log_handler_fn_t *handler, int def)
 {
     ap_log_handler *log_struct = apr_palloc(p, sizeof(*log_struct));
@@ -1329,7 +1329,7 @@
 }
 static ap_log_writer_init* ap_log_set_writer_init(ap_log_writer_init *handle)
 {
-    ap_log_writer_init *old = log_writer_init; 
+    ap_log_writer_init *old = log_writer_init;
     log_writer_init = handle;
 
     return old;
@@ -1337,14 +1337,14 @@
 }
 static ap_log_writer *ap_log_set_writer(ap_log_writer *handle)
 {
-    ap_log_writer *old = log_writer; 
+    ap_log_writer *old = log_writer;
     log_writer = handle;
 
     return old;
 }
 
 static apr_status_t ap_default_log_writer( request_rec *r,
-                           void *handle, 
+                           void *handle,
                            const char **strs,
                            int *strl,
                            int nelts,
@@ -1367,7 +1367,7 @@
 
     return rv;
 }
-static void *ap_default_log_writer_init(apr_pool_t *p, server_rec *s, 
+static void *ap_default_log_writer_init(apr_pool_t *p, server_rec *s,
                                         const char* name)
 {
     if (*name == '|') {
@@ -1398,13 +1398,13 @@
         return fd;
     }
 }
-static void *ap_buffered_log_writer_init(apr_pool_t *p, server_rec *s, 
+static void *ap_buffered_log_writer_init(apr_pool_t *p, server_rec *s,
                                         const char* name)
 {
     buffered_log *b;
     b = apr_pcalloc(p, sizeof(buffered_log));
     b->handle = ap_default_log_writer_init(p, s, name);
-    
+
     if (b->handle) {
         *(buffered_log **)apr_array_push(all_buffered_logs) = b;
         return b;
@@ -1413,7 +1413,7 @@
         return NULL;
 }
 static apr_status_t ap_buffered_log_writer(request_rec *r,
-                                           void *handle, 
+                                           void *handle,
                                            const char **strs,
                                            int *strl,
                                            int nelts,
@@ -1443,7 +1443,7 @@
         }
         w = len;
         rv = apr_file_write(buf->handle, str, &w);
-        
+
     }
     else {
         for (i = 0, s = &buf->outbuf[buf->outcnt]; i < nelts; ++i) {
@@ -1461,7 +1461,7 @@
 static int log_pre_config(apr_pool_t *p, apr_pool_t *plog, apr_pool_t *ptemp)
 {
     static APR_OPTIONAL_FN_TYPE(ap_register_log_handler) *log_pfn_register;
-    
+
     log_pfn_register = APR_RETRIEVE_OPTIONAL_FN(ap_register_log_handler);
 
     if (log_pfn_register) {
@@ -1504,12 +1504,12 @@
     ap_hook_open_logs(init_config_log,NULL,NULL,APR_HOOK_MIDDLE);
     ap_hook_log_transaction(multi_log_transaction,NULL,NULL,APR_HOOK_MIDDLE);
 
-    /* Init log_hash before we register the optional function. It is 
+    /* Init log_hash before we register the optional function. It is
      * possible for the optional function, ap_register_log_handler,
      * to be called before any other mod_log_config hooks are called.
      * As a policy, we should init everything required by an optional function
      * before calling APR_REGISTER_OPTIONAL_FN.
-     */ 
+     */
     log_hash = apr_hash_make(p);
     APR_REGISTER_OPTIONAL_FN(ap_register_log_handler);
     APR_REGISTER_OPTIONAL_FN(ap_log_set_writer_init);

Modified: httpd/httpd/trunk/modules/loggers/mod_log_forensic.c
URL: http://svn.apache.org/viewcvs/httpd/httpd/trunk/modules/loggers/mod_log_forensic.c?rev=332306&r1=332305&r2=332306&view=diff
==============================================================================
--- httpd/httpd/trunk/modules/loggers/mod_log_forensic.c (original)
+++ httpd/httpd/trunk/modules/loggers/mod_log_forensic.c Thu Nov 10 07:11:44 2005
@@ -115,7 +115,7 @@
     return OK;
 }
 
-  
+
 /* e is the first _invalid_ location in q
    N.B. returns the terminating NUL.
  */

Modified: httpd/httpd/trunk/modules/loggers/mod_logio.c
URL: http://svn.apache.org/viewcvs/httpd/httpd/trunk/modules/loggers/mod_logio.c?rev=332306&r1=332305&r2=332306&view=diff
==============================================================================
--- httpd/httpd/trunk/modules/loggers/mod_logio.c (original)
+++ httpd/httpd/trunk/modules/loggers/mod_logio.c Thu Nov 10 07:11:44 2005
@@ -139,7 +139,7 @@
 static int logio_pre_config(apr_pool_t *p, apr_pool_t *plog, apr_pool_t *ptemp)
 {
     static APR_OPTIONAL_FN_TYPE(ap_register_log_handler) *log_pfn_register;
-    
+
     log_pfn_register = APR_RETRIEVE_OPTIONAL_FN(ap_register_log_handler);
 
     if (log_pfn_register) {

Modified: httpd/httpd/trunk/modules/mappers/mod_actions.c
URL: http://svn.apache.org/viewcvs/httpd/httpd/trunk/modules/mappers/mod_actions.c?rev=332306&r1=332305&r2=332306&view=diff
==============================================================================
--- httpd/httpd/trunk/modules/mappers/mod_actions.c (original)
+++ httpd/httpd/trunk/modules/mappers/mod_actions.c Thu Nov 10 07:11:44 2005
@@ -23,9 +23,9 @@
  * Usage instructions:
  *
  * Action mime/type /cgi-bin/script
- * 
- * will activate /cgi-bin/script when a file of content type mime/type is 
- * requested. It sends the URL and file path of the requested document using 
+ *
+ * will activate /cgi-bin/script when a file of content type mime/type is
+ * requested. It sends the URL and file path of the requested document using
  * the standard CGI PATH_INFO and PATH_TRANSLATED environment variables.
  *
  * Script PUT /cgi-bin/script
@@ -89,7 +89,7 @@
     return new;
 }
 
-static const char *add_action(cmd_parms *cmd, void *m_v, 
+static const char *add_action(cmd_parms *cmd, void *m_v,
                               const char *type, const char *script,
                               const char *option)
 {
@@ -110,8 +110,8 @@
 static const char *set_script(cmd_parms *cmd, void *m_v,
                               const char *method, const char *script)
 {
-    action_dir_config *m = (action_dir_config *)m_v;    
-    
+    action_dir_config *m = (action_dir_config *)m_v;
+
     /* ap_method_register recognizes already registered methods,
      * so don't bother to check its previous existence explicitely.
      */

Modified: httpd/httpd/trunk/modules/mappers/mod_alias.c
URL: http://svn.apache.org/viewcvs/httpd/httpd/trunk/modules/mappers/mod_alias.c?rev=332306&r1=332305&r2=332306&view=diff
==============================================================================
--- httpd/httpd/trunk/modules/mappers/mod_alias.c (original)
+++ httpd/httpd/trunk/modules/mappers/mod_alias.c Thu Nov 10 07:11:44 2005
@@ -16,10 +16,10 @@
 
 /*
  * http_alias.c: Stuff for dealing with directory aliases
- * 
+ *
  * Original by Rob McCool, rewritten in succession by David Robinson
  * and rst.
- * 
+ *
  */
 
 #include "apr_strings.h"
@@ -168,7 +168,7 @@
 
 static const char *add_redirect_internal(cmd_parms *cmd,
                                          alias_dir_conf *dirconf,
-                                         const char *arg1, const char *arg2, 
+                                         const char *arg1, const char *arg2,
                                          const char *arg3, int use_regex)
 {
     alias_entry *new;
@@ -258,14 +258,14 @@
                   "a regular expression and a filename"),
     AP_INIT_TAKE2("ScriptAliasMatch", add_alias_regex, "cgi-script", RSRC_CONF,
                   "a regular expression and a filename"),
-    AP_INIT_TAKE23("RedirectMatch", add_redirect_regex, 
+    AP_INIT_TAKE23("RedirectMatch", add_redirect_regex,
                    (void *) HTTP_MOVED_TEMPORARILY, OR_FILEINFO,
                    "an optional status, then a regular expression and "
                    "destination URL"),
     AP_INIT_TAKE2("RedirectTemp", add_redirect2,
                   (void *) HTTP_MOVED_TEMPORARILY, OR_FILEINFO,
                   "a document to be redirected, then the destination URL"),
-    AP_INIT_TAKE2("RedirectPermanent", add_redirect2, 
+    AP_INIT_TAKE2("RedirectPermanent", add_redirect2,
                   (void *) HTTP_MOVED_PERMANENTLY, OR_FILEINFO,
                   "a document to be redirected, then the destination URL"),
     {NULL}
@@ -331,15 +331,15 @@
                         apr_uri_t uri;
                         apr_uri_parse(r->pool, found, &uri);
                         /* Do not escape the query string or fragment. */
-                        found = apr_uri_unparse(r->pool, &uri, 
+                        found = apr_uri_unparse(r->pool, &uri,
                                                 APR_URI_UNP_OMITQUERY);
                         found = ap_escape_uri(r->pool, found);
                         if (uri.query) {
-                            found = apr_pstrcat(r->pool, found, "?", 
+                            found = apr_pstrcat(r->pool, found, "?",
                                                 uri.query, NULL);
                         }
                         if (uri.fragment) {
-                            found = apr_pstrcat(r->pool, found, "#", 
+                            found = apr_pstrcat(r->pool, found, "#",
                                                 uri.fragment, NULL);
                         }
                     }



Mime
View raw message