Author: markt
Date: Sun Mar  6 07:17:07 2011
New Revision: 1078409

URL: http://svn.apache.org/viewvc?rev=1078409&view=rev
Log:
Fix threading issue reported on dev list

Modified:
    tomcat/trunk/java/org/apache/jasper/servlet/JspServletWrapper.java
    tomcat/trunk/webapps/docs/changelog.xml

Modified: tomcat/trunk/java/org/apache/jasper/servlet/JspServletWrapper.java
URL: 
http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/jasper/servlet/JspServletWrapper.java?rev=1078409&r1=1078408&r2=1078409&view=diff
==============================================================================
--- tomcat/trunk/java/org/apache/jasper/servlet/JspServletWrapper.java 
(original)
+++ tomcat/trunk/java/org/apache/jasper/servlet/JspServletWrapper.java Sun Mar  
6 07:17:07 2011
@@ -312,6 +312,8 @@ public class JspServletWrapper {
                         boolean precompile)
             throws ServletException, IOException, FileNotFoundException {
         
+        Servlet servlet;
+
         try {
 
             if (ctxt.isRemoved()) {
@@ -351,7 +353,7 @@ public class JspServletWrapper {
             /*
              * (2) (Re)load servlet class file
              */
-            getServlet();
+            servlet = getServlet();
 
             // If a page is to be precompiled only, return.
             if (precompile) {
@@ -407,14 +409,14 @@ public class JspServletWrapper {
             /*
              * (4) Service request
              */
-            if (theServlet instanceof SingleThreadModel) {
+            if (servlet instanceof SingleThreadModel) {
                // sync on the wrapper so that the freshness
                // of the page is determined right before servicing
                synchronized (this) {
-                   theServlet.service(request, response);
+                   servlet.service(request, response);
                 }
             } else {
-                theServlet.service(request, response);
+                servlet.service(request, response);
             }
         } catch (UnavailableException ex) {
             String includeRequestUri = (String)

Modified: tomcat/trunk/webapps/docs/changelog.xml
URL: 
http://svn.apache.org/viewvc/tomcat/trunk/webapps/docs/changelog.xml?rev=1078409&r1=1078408&r2=1078409&view=diff
==============================================================================
--- tomcat/trunk/webapps/docs/changelog.xml (original)
+++ tomcat/trunk/webapps/docs/changelog.xml Sun Mar  6 07:17:07 2011
@@ -42,6 +42,16 @@
   General, Catalina, Coyote, Jasper, Cluster, Web applications, Extras, Tribes,
   Other
 -->
+<section name="Tomcat 7.0.11 (markt)">
+  <subsection name="Jasper">
+    <changelog>
+      <fix>
+        Correct possible threading issue in JSP compilation when development
+        mode is used. (markt)
+      </fix>
+    </changelog>
+  </subsection>
+</section>
 <section name="Tomcat 7.0.10 (markt)">
   <subsection name="Catalina">
     <changelog>



---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to