httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "William A. Rowe Jr." <>
Subject Re: Fwd: mod_substitute buggy execution order
Date Tue, 20 Dec 2011 08:29:22 GMT
On 12/20/2011 1:44 AM, Nick Gearls wrote:
> That's very different from other modules.
> Most (all?) modules do the opposite: first global, then local - ex: rewrite
> Furthermore, narrowing does not work the way you expect as
>    <Location /test/>
>      Substitute  "s/aaa/local1/inq"
>    </Location>
>    <Location />
>      Substitute  "s/aaa/local2/inq"
>      Substitute  "s/aaa/local3/inq"
>    </Location>
> will end up with "local2" which is not the narrowest-scope.
> I understand your concern, but this definitely breaks the usual way of working which
> introduces an inconsistency with other modules .

This is clearly broken, if you in fact tested this particular example.

But again, I'm not sure we can alter the behavior without silently breaking
existing configurations.  It doesn't seem very well thought out, but again
it's already been replaced.

>> mod_substitute is gone from 2.4
> Is it replaced by mod_sed? What is the logic there?

It's an independently developed module, I can't tell you offhand
how it behaves.

We might be safer backporting mod_sed to 2.2 and deprecating mod_substitute
in that tree for users who need the correct behavior.

In any case, patches to the docs to clarify this behavior for the users
would absolutely be welcome!!!

View raw message