Commit 9f17cd6c authored by Roy T. Fielding's avatar Roy T. Fielding
Browse files

Revert addition of HTTP logging hhok for connection status -- this is not

specific to HTTP.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@88907 13f79535-47bb-0310-9956-ffa450edef68
parent 93df069b
Loading
Loading
Loading
Loading
+0 −31
Original line number Diff line number Diff line
@@ -59,7 +59,6 @@
#include "apr_strings.h"
#include "apr_thread_proc.h"    /* for RLIMIT stuff */
#include "apr_lib.h"
#include "apr_optional.h"

#define APR_WANT_STRFUNC
#include "apr_want.h"
@@ -78,7 +77,6 @@
#include "scoreboard.h"

#include "mod_core.h"
#include "../loggers/mod_log_config.h"

static const char *set_keep_alive_timeout(cmd_parms *cmd, void *dummy,
					  const char *arg)
@@ -444,37 +442,8 @@ static int http_create_request(request_rec *r)
    return OK;
}

static const char *log_connection_status(request_rec *r, char *a)
{
    ap_http_conn_rec *hconn = ap_get_module_config(r->connection->conn_config,
                                                &http_module);
    if (r->connection->aborted)
        return "X";
 
    if ((r->connection->keepalive) &&
        ((r->server->keep_alive_max - hconn->keepalives) > 0)) {
        return "+";
    }
 
    return "-";
}

static void http_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) {
        log_pfn_register(p, "c", log_connection_status, 0); 
    }
}

static void register_hooks(apr_pool_t *p)
{
    static const char *const pred[] = { "mod_log_config.c", NULL };    

    ap_hook_pre_config(http_pre_config, pred, NULL, APR_HOOK_MIDDLE);
    ap_hook_pre_connection(ap_pre_http_connection,NULL,NULL,
			       APR_HOOK_REALLY_LAST);
    ap_hook_process_connection(ap_process_http_connection,NULL,NULL,