Index: server/core.c =================================================================== --- server/core.c (revision 1042903) +++ server/core.c (working copy) @@ -73,6 +73,9 @@ #define AP_MAX_INCLUDE_DEPTH (128) #endif +/* valid in core-conf, but not in runtime r->used_path_info */ +#define AP_ACCEPT_PATHINFO_UNSET 3 + APR_HOOK_STRUCT( APR_HOOK_LINK(get_mgmt_items) ) @@ -120,7 +123,7 @@ conf->override_opts = OPT_UNSET | OPT_ALL | OPT_SYM_OWNER | OPT_MULTI; conf->content_md5 = 2; - conf->accept_path_info = 3; + conf->accept_path_info = AP_ACCEPT_PATHINFO_UNSET; conf->use_canonical_name = USE_CANONICAL_NAME_UNSET; conf->use_canonical_phys_port = USE_CANONICAL_PHYS_PORT_UNSET; @@ -3759,15 +3762,17 @@ /* Deal with the poor soul who is trying to force path_info to be * accepted within the core_handler, where they will let the subreq * address its contents. This is toggled by the user in the very - * beginning of the fixup phase, so modules should override the user's + * beginning of the fixup phase (here!), so modules should override the user's * discretion in their own module fixup phase. It is tristate, if - * the user doesn't specify, the result is 2 (which the module may - * interpret to its own customary behavior.) It won't be touched - * if the value is no longer undefined (2), so any module changing - * the value prior to the fixup phase OVERRIDES the user's choice. + * the user doesn't specify, the result is AP_REQ_DEFAULT_PATH_INFO. + * (which the module may interpret to its own customary behavior.) + * It won't be touched if the value is no longer AP_ACCEPT_PATHINFO_UNSET, + * so any module changing the value prior to the fixup phase + * OVERRIDES the user's choice. */ if ((r->used_path_info == AP_REQ_DEFAULT_PATH_INFO) - && (conf->accept_path_info != 3)) { + && (conf->accept_path_info != AP_ACCEPT_PATHINFO_UNSET)) { + /* No module knew better, and the user coded AcceptPathInfo */ r->used_path_info = conf->accept_path_info; } Index: modules/http/http_request.c =================================================================== --- modules/http/http_request.c (revision 1042903) +++ modules/http/http_request.c (working copy) @@ -521,6 +521,11 @@ apr_table_setn(new->subprocess_env, "REDIRECT_STATUS", apr_itoa(r->pool, r->status)); + /* Begin by presuming any module can make its own path_info assumptions, + * until some module interjects and changes the value. + */ + new->used_path_info = AP_REQ_DEFAULT_PATH_INFO; + /* * XXX: hmm. This is because mod_setenvif and mod_unique_id really need * to do their thing on internal redirects as well. Perhaps this is a