1
0
mirror of https://github.com/apache/httpd.git synced 2025-08-07 04:02:58 +03:00

Move the quick_handler comment to the new quick handler location. Do not

call quick handler on a dirent subrequest. This fixes a nasty problem in
mod_cache where it was serving up content on a dirent subrequest.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@93915 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Bill Stoddard
2002-03-13 19:41:56 +00:00
parent ff76c93622
commit 6752a95e45
2 changed files with 27 additions and 25 deletions

View File

@@ -239,24 +239,6 @@ void ap_process_request(request_rec *r)
{
int access_status;
/* Give quick handlers a shot at serving the request on the fast
* path, bypassing all of the other Apache hooks.
*
* This hook was added to enable serving files out of a URI keyed
* content cache ( e.g., Mike Abbott's Quick Shortcut Cache,
* described here: http://oss.sgi.com/projects/apache/mod_qsc.html )
*
* It may have other uses as well, such as routing requests directly to
* content handlers that have the ability to grok HTTP and do their
* own access checking, etc (e.g. servlet engines).
*
* Use this hook with extreme care and only if you know what you are
* doing.
*
* Consider moving this hook to after the first location_walk in order
* to enable the quick handler to make decisions based on config
* directives in Location blocks.
*/
access_status = ap_process_request_internal(r);
if (access_status == OK) {
access_status = ap_invoke_handler(r);

View File

@@ -145,13 +145,33 @@ AP_DECLARE(int) ap_process_request_internal(request_rec *r)
int file_req = (r->main && r->filename);
int access_status;
access_status = ap_run_quick_handler(r);
if (access_status != DECLINED) {
if (access_status == OK) {
return DONE;
}
else {
return access_status;
/* Give quick handlers a shot at serving the request on the fast
* path, bypassing all of the other Apache hooks. Bypass the call
* for dirent subrequests (any other cases to bypass?)
*
* This hook was added to enable serving files out of a URI keyed
* content cache ( e.g., Mike Abbott's Quick Shortcut Cache,
* described here: http://oss.sgi.com/projects/apache/mod_qsc.html )
*
* It may have other uses as well, such as routing requests directly to
* content handlers that have the ability to grok HTTP and do their
* own access checking, etc (e.g. servlet engines).
*
* Use this hook with extreme care and only if you know what you are
* doing. This hook is available to (non dirent) subrequests.
*/
if (!(r->main && r->filename && r->finfo.filetype)) {
/* TODO?: Add a field to the request_rec explicitly identifying
* the type of subrequest?
*/
access_status = ap_run_quick_handler(r);
if (access_status != DECLINED) {
if (access_status == OK) {
return DONE;
}
else {
return access_status;
}
}
}