Port of fix for bug 39592. Stop stack traces for HEAD requests.
authormarkt <markt@13f79535-47bb-0310-9956-ffa450edef68>
Thu, 27 Jul 2006 00:34:35 +0000 (00:34 +0000)
committermarkt <markt@13f79535-47bb-0310-9956-ffa450edef68>
Thu, 27 Jul 2006 00:34:35 +0000 (00:34 +0000)
git-svn-id: https://svn.apache.org/repos/asf/tomcat/tc6.0.x/trunk@425918 13f79535-47bb-0310-9956-ffa450edef68

java/org/apache/catalina/ssi/SSIServletExternalResolver.java

index 16e3519..9b0c764 100644 (file)
@@ -533,7 +533,8 @@ public class SSIServletExternalResolver implements SSIExternalResolver {
             // a problem
             // if a truly empty file
             //were included, but not sure how else to tell.
-            if (retVal.equals("")) {
+            if (retVal.equals("") && !req.getMethod().equalsIgnoreCase(
+                    org.apache.coyote.http11.Constants.HEAD)) {
                 throw new IOException("Couldn't find file: " + path);
             }
             return retVal;