Summary: | Unexpected Warnings from Macro Use in 2.4 | ||
---|---|---|---|
Product: | Apache httpd-2 | Reporter: | Tom Browder <tom.browder> |
Component: | mod_macro | Assignee: | Apache HTTPD Bugs Mailing List <bugs> |
Status: | RESOLVED FIXED | ||
Severity: | normal | CC: | rjollos, tom.browder |
Priority: | P2 | ||
Version: | 2.5-HEAD | ||
Target Milestone: | --- | ||
Hardware: | All | ||
OS: | All | ||
Attachments: | Add warning about syntax clash |
Description
Tom Browder
2015-08-30 17:01:19 UTC
${VAR} is interpreted as a defined variable (http://httpd.apache.org/docs/2.4/mod/core.html#define). It's equivalent to %{VAR}. mod_macro uses the syntax $var but also ${var}, which is mandatory if you want the variable to be a part of a string, like in "${var}abc". The syntax clashes with the Define directive, so it should be changed. Ans %{var} clashes with mod_rewrite. This doe not only give a warning but could lead to a real mismatch between something defined as a local parameter and somebody else defining it at a global level as a defined config variable. To make interpolation not clash with another module, we should use another character (instead of an existing one or on top of?) like &{var}. Created attachment 34013 [details]
Add warning about syntax clash
In case a macro argument uses the syntax ${...}, adds a warning that it clashes with the 'Define' directive
|