Prevent double init() of JSP
Patch provided by Chris Halstead
git-svn-id: https://svn.apache.org/repos/asf/tomcat/trunk@759074
13f79535-47bb-0310-9956-
ffa450edef68
String[] smap = generateJava();
if (compileClass) {
generateClass(smap);
+ // Fix for bugzilla 41606
+ // Set JspServletWrapper.servletClassLastModifiedTime after successful compile
+ String targetFileName = ctxt.getClassFileName();
+ if (targetFileName != null) {
+ File targetFile = new File(targetFileName);
+ if (targetFile.exists() && jsw != null) {
+ jsw.setServletClassLastModifiedTime(targetFile.lastModified());
+ }
+ }
}
} finally {
if (tfp != null && ctxt.isPrototypeMode()) {