You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@perl.apache.org by Stas Bekman <st...@stason.org> on 2002/06/05 17:00:51 UTC

todo/api.txt log_reason

todo/api.txt
-------------
$r->log_reason:
should be simple, see modperl_log.h

Doug are we planning on implementing this one in-core, and the recent 
addition of the compat implementation was only tmp?


__________________________________________________________________
Stas Bekman            JAm_pH ------> Just Another mod_perl Hacker
http://stason.org/     mod_perl Guide ---> http://perl.apache.org
mailto:stas@stason.org http://use.perl.org http://apacheweek.com
http://modperlbook.org http://apache.org   http://ticketmaster.com


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@perl.apache.org
For additional commands, e-mail: dev-help@perl.apache.org


Re: todo/api.txt log_reason

Posted by Stas Bekman <st...@stason.org>.
Doug MacEachern wrote:
> On Wed, 5 Jun 2002, Stas Bekman wrote:
> 
> 
>>todo/api.txt
>>-------------
>>$r->log_reason:
>>should be simple, see modperl_log.h
>>
>>Doug are we planning on implementing this one in-core, and the recent 
>>addition of the compat implementation was only tmp?
> 
> 
> dunno.  somebody needs to figure out why ap_log_reason was removed from 
> the apache2 api.  is there another api that does the same thing?  or log 
> format?  or something else?

I've asked at #apr, nobody seems to know.

So this implementation in modperl_log.h is supposed to be what?

#define modperl_log_reason(r,msg,file) \
     ap_log_error(APLOG_MARK, APLOG_ERR|APLOG_NOERRNO, 0, r->server, \
                  "access to %s failed for %s, reason: %s", \
                  file, \
                  get_remote_host(r->connection, \
                  r->per_dir_config, REMOTE_NAME), \
                  msg)


may be we just use the following compat function:

sub log_reason {
     my ($r, $reason, $filename) = @_;

     $r->log_error(sprintf "access to %s failed for %s, reason: %s",
                   $filename,
                   $r->connection->remote_host,
                   $reason);
}

or is there a need for the C-level API compat here?


__________________________________________________________________
Stas Bekman            JAm_pH ------> Just Another mod_perl Hacker
http://stason.org/     mod_perl Guide ---> http://perl.apache.org
mailto:stas@stason.org http://use.perl.org http://apacheweek.com
http://modperlbook.org http://apache.org   http://ticketmaster.com


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@perl.apache.org
For additional commands, e-mail: dev-help@perl.apache.org


Re: todo/api.txt log_reason

Posted by Doug MacEachern <do...@covalent.net>.
On Wed, 5 Jun 2002, Stas Bekman wrote:

> todo/api.txt
> -------------
> $r->log_reason:
> should be simple, see modperl_log.h
> 
> Doug are we planning on implementing this one in-core, and the recent 
> addition of the compat implementation was only tmp?

dunno.  somebody needs to figure out why ap_log_reason was removed from 
the apache2 api.  is there another api that does the same thing?  or log 
format?  or something else?


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@perl.apache.org
For additional commands, e-mail: dev-help@perl.apache.org