Commit 4d3526bb authored by Cliff Woolley's avatar Cliff Woolley
Browse files

Fix a segfault (was getting triggered by mod_include at least) caused

by calling ap_allow_options() before setting rnew->per_dir_config.

This is the "easy looking" fix but might have side effects of which I'm
unaware... please double-check this change for correctness.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@89978 13f79535-47bb-0310-9956-ffa450edef68
parent f98a027a
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -1510,6 +1510,8 @@ AP_DECLARE(request_rec *) ap_sub_req_lookup_file(const char *new_file,
        rnew->filename = ap_make_full_path(rnew->pool, fdir, new_file);
        ap_parse_uri(rnew, rnew->uri);    /* fill in parsed_uri values */

        rnew->per_dir_config = r->per_dir_config;

        /*
         * If this is an APR_LNK that resolves to an APR_DIR, then 
         * we will rerun everything anyways... this should be safe.
@@ -1531,8 +1533,6 @@ AP_DECLARE(request_rec *) ap_sub_req_lookup_file(const char *new_file,
            return rnew;
        }

        rnew->per_dir_config = r->per_dir_config;

        if (rnew->finfo.filetype == APR_LNK
            && (res = resolve_symlink(rnew->filename, &rnew->finfo, 
                                      ap_allow_options(rnew), rnew->pool)) != OK) {