~ubuntu-branches/ubuntu/karmic/apache2/karmic-security

« back to all changes in this revision

Viewing changes to modules/filters/mod_ext_filter.c

  • Committer: Bazaar Package Importer
  • Author(s): Stefan Fritsch
  • Date: 2008-10-01 11:50:18 UTC
  • mfrom: (34 intrepid)
  • mto: (14.2.1 squeeze)
  • mto: This revision was merged to the branch mainline in revision 40.
  • Revision ID: james.westby@ubuntu.com-20081001115018-1022gw429ce4pqyp
Tags: 2.2.9-10
Regression fix from upstream svn for mod_proxy_http:
Don't trigger a retry by the client if a failure to read the response line
was the result of a timeout.

Show diffs side-by-side

added added

removed removed

Lines of Context:
206
206
                                             &ext_filter_module);
207
207
    const char *token;
208
208
    const char *name;
 
209
    char *normalized_name;
209
210
    ef_filter_t *filter;
210
211
 
211
212
    name = ap_getword_white(cmd->pool, &args);
213
214
        return "Filter name not found";
214
215
    }
215
216
 
216
 
    if (apr_hash_get(conf->h, name, APR_HASH_KEY_STRING)) {
 
217
    /* During request processing, we find information about the filter
 
218
     * by looking up the filter name provided by core server in our
 
219
     * hash table.  But the core server has normalized the filter
 
220
     * name by converting it to lower case.  Thus, when adding the
 
221
     * filter to our hash table we have to use lower case as well.
 
222
     */
 
223
    normalized_name = apr_pstrdup(cmd->pool, name);
 
224
    ap_str_tolower(normalized_name);
 
225
 
 
226
    if (apr_hash_get(conf->h, normalized_name, APR_HASH_KEY_STRING)) {
217
227
        return apr_psprintf(cmd->pool, "ExtFilter %s is already defined",
218
228
                            name);
219
229
    }
222
232
    filter->name = name;
223
233
    filter->mode = OUTPUT_FILTER;
224
234
    filter->ftype = AP_FTYPE_RESOURCE;
225
 
    apr_hash_set(conf->h, name, APR_HASH_KEY_STRING, filter);
 
235
    apr_hash_set(conf->h, normalized_name, APR_HASH_KEY_STRING, filter);
226
236
 
227
237
    while (*args) {
228
238
        while (apr_isspace(*args)) {