On Mon, 2002-10-07 at 10:37, Doug MacEachern wrote: > thanks, applied. > note that while the method works at request time, it is not thread safe. > of course, the 1.x method was never meant to be used at request time. > could change to use $r->add_config if Apache->request is available just in > case. >
Like this ?
Index: lib/Apache/compat.pm
===================================================================
RCS file: /home/cvspublic/modperl-2.0/lib/Apache/compat.pm,v
retrieving revision 1.67
diff -u -I'$Id' -I'$Revision' -r1.67 compat.pm
--- lib/Apache/compat.pm 7 Oct 2002 02:44:30 -0000 1.67
+++ lib/Apache/compat.pm 7 Oct 2002 04:15:21 -0000
@@ -112,7 +112,7 @@
sub httpd_conf {
shift;
- my $err = Apache->server->add_config([split /\n/, join '', @_]);
+ my $err = (Apache->request || Apache->server)->add_config([split /\n/, join '',
+@_]);
die $err if $err;
}
--
Philippe M. Chiasson <[EMAIL PROTECTED]>
eXtropia Pte. Ltd.
signature.asc
Description: This is a digitally signed message part
