Joe Orton wrote:
On Mon, Feb 14, 2005 at 08:53:44AM -0500, Geoffrey Young wrote:

looks ok to me, though it means that in addition to

 have_module('mod_rewrite.c');
 have_module('mod_rewrite');

working

 have_module('rewrite');
 have_module('rewrite.c');

will also work. hopefully that is intuitive instead of confusing :)


Indeed! OK thanks, committed that.

Where did the commit message go? I didn't get any.

If you look at the current code with your latest commit Joe, it tries to deal with the same issue twice. The unless condition already tries to tackle that, but won't do it if there is no c extension.

            unless ($mod =~ /\.c$/) {
                $mod = 'mod_' . $mod unless $mod =~ /^mod_/;
                $mod .= '.c'
            }
            next if $cfg->{modules}->{$mod};
            next if $cfg->{modules}->{'mod_' . $mod };

just change that to be:

            $mod = 'mod_' . $mod unless $mod =~ /^mod_/;
            $mod .= '.c' unless $mod =~ /\.c$/
            next if $cfg->{modules}->{$mod};

and you have a much cleaner solution.

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

Reply via email to