httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Ondrej Sury <ond...@sury.org>
Subject Re: Pluggable mod_log_config
Date Mon, 03 Oct 2005 14:19:02 GMT
On Mon, 2005-10-03 at 09:35 -0400, Brian Akins wrote:
> Ondrej Sury wrote:
> 
> > You also need to store which writer to use in each config_log_state.
> 
> This is already done.

Nope, (void *)cls->log_writer is pointer to log file descriptor.

> Also, init is called for each CustomLog config entry.

Yep, but only ap_log_writer_init is called.  You need to do something
like that:

foreach provider in ap_log_writer_providers {
	cls->log_writer = provider->init(...., &cls->log_data);

	if (cls->log_writer) {
		break;
	}
}

Then later when writing log you need to call

cls->log_writer(..., cls->log_data, ...)

instead of just

log_writer(...)

Ondrej.
-- 
Ondrej Sury <ondrej@sury.org>

Mime
View raw message