perl-modperl mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From René Seindal <r...@seindal.dk>
Subject Re: Apache::StatINC.pm
Date Tue, 28 Mar 2000 03:58:57 GMT
Ken Williams wrote:
> 
> rene@seindal.dk (René Seindal) wrote:
> >I just got bitten by the problem of Apache::StatINC not reloading
> >modules found through an element of @INC, which is no longer present
> >when StatINC runs.
> [...]
> >A small change to StatINC solves the problem. Since StatINC could stat
> >the file, the file is accessible, only not through require(). The fix is
> >to change StatINC to load the file instead of the module, which is
> >achieved with this little patch (against 1.06 from mod_perl 1.21, but
> >nothing seems to have changed):
> 
> I've been in favor of this change for a long time.  I last suggested it here:
>   http://forum.swarthmore.edu/epigone/modperl/stexlorblay
> I'm still in favor, perhaps this time it will happen?  The only problem seems
> to happen when people use relative pathnames to source files, which is a bad
> idea under mod_perl anyway.

If both ways cause problems, then the right solution is to leave it to
the user.  Apache::StatINC already uses dir_config() to adjust its
behaviour according to user preferences, so adding another configuration
variable can't be a problem.  Current behaviour would be the default and
setting a variable with PerlSetVar would change it to what we have
proposed.

I'll make a patch relative to the cvs version if there is any change
such a change would make it into the distribution.  It will inspect a
PerlSetVar parameter, and use require() or do() accordingly - couldn't
be simpler.

-- 
René Seindal (rene@seindal.dk)			http://www.seindal.dk/rene/

Mime
View raw message