* follows:
*
* %...b: bytes sent, excluding HTTP headers.
+ * %...c: Status of the connection.
+ * 'X' = connection aborted before the response completed.
+ * '+' = connection may be kept alive after the response is sent.
+ * '-' = connection will be closed after the response is sent.
* %...{FOOBAR}e: The contents of the environment variable FOOBAR
* %...f: filename
* %...h: remote host
{
return apr_psprintf(r->pool, "%ld", (long) getpid());
}
+static const char *log_connection_status(request_rec *r, char *a)
+{
+ if (r->connection->aborted)
+ return "X";
+
+ if ((r->connection->keepalive) &&
+ ((r->server->keep_alive_max - r->connection->keepalives) > 0)) {
+ return "+";
+ }
+ return "-";
+}
/*****************************************************************
*
* Parsing the log format string
{
'P', log_child_pid, 0
},
+ {
+ 'c', log_connection_status, 0
+ },
{
'\0'
}