View | Details | Raw Unified | Return to bug 41867
Collapse All | Expand All

(-)include/http_core.h (+1 lines)
Lines 619-624 Link Here
619
619
620
    unsigned int allow_encoded_slashes_set : 1;
620
    unsigned int allow_encoded_slashes_set : 1;
621
    unsigned int decode_encoded_slashes_set : 1;
621
    unsigned int decode_encoded_slashes_set : 1;
622
    unsigned int d_is_directory : 1;
622
623
623
    /** Named back references */
624
    /** Named back references */
624
    apr_array_header_t *refs;
625
    apr_array_header_t *refs;
(-)server/core.c (+1 lines)
Lines 2224-2229 Link Here
2224
    conf->r = r;
2224
    conf->r = r;
2225
    conf->d = cmd->path;
2225
    conf->d = cmd->path;
2226
    conf->d_is_fnmatch = (apr_fnmatch_test(conf->d) != 0);
2226
    conf->d_is_fnmatch = (apr_fnmatch_test(conf->d) != 0);
2227
    conf->d_is_directory = 1;
2227
2228
2228
    if (r) {
2229
    if (r) {
2229
        conf->refs = apr_array_make(cmd->pool, 8, sizeof(char *));
2230
        conf->refs = apr_array_make(cmd->pool, 8, sizeof(char *));
(-)server/request.c (+16 lines)
Lines 910-915 Link Here
910
                    break;
910
                    break;
911
                }
911
                }
912
912
913
                /* Last conf_dir_config is Directory*, but the requested file
914
                 * is not a directory, so although the prefix could match,
915
                 * we skip it. */
916
                if (entry_core->d_is_directory && sec_idx == num_sec - 1
917
                    && r->finfo.filetype != APR_DIR) {
918
                    continue;
919
                }
920
913
                /* We will never skip '0' element components, e.g. plain old
921
                /* We will never skip '0' element components, e.g. plain old
914
                 * <Directory >, and <Directory "/"> are classified as zero
922
                 * <Directory >, and <Directory "/"> are classified as zero
915
                 * so that Win32/Netware/OS2 etc all pick them up.
923
                 * so that Win32/Netware/OS2 etc all pick them up.
Lines 1216-1221 Link Here
1216
                pmatch = apr_palloc(rxpool, nmatch*sizeof(ap_regmatch_t));
1224
                pmatch = apr_palloc(rxpool, nmatch*sizeof(ap_regmatch_t));
1217
            }
1225
            }
1218
1226
1227
            /* Last conf_dir_config is Directory*, but the requested file is
1228
             * not a directory, so although the regexp could match,
1229
             * so we skip it. */
1230
            if (entry_core->d_is_directory && sec_idx == num_sec - 1
1231
                && r->finfo.filetype != APR_DIR) {
1232
                continue;
1233
            }
1234
1219
            if (ap_regexec(entry_core->r, r->filename, nmatch, pmatch, 0)) {
1235
            if (ap_regexec(entry_core->r, r->filename, nmatch, pmatch, 0)) {
1220
                continue;
1236
                continue;
1221
            }
1237
            }

Return to bug 41867