You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tomcat.apache.org by bu...@apache.org on 2018/10/02 09:13:04 UTC
[Bug 62792] New: Race condition NullpointerException in
JspServletWrapper
https://bz.apache.org/bugzilla/show_bug.cgi?id=62792
Bug ID: 62792
Summary: Race condition NullpointerException in
JspServletWrapper
Product: Tomcat 9
Version: 9.0.12
Hardware: PC
OS: Linux
Status: NEW
Severity: normal
Priority: P2
Component: Jasper
Assignee: dev@tomcat.apache.org
Reporter: julien@beti.name
Target Milestone: -----
We do have the following NullPointerException in Tomcat 9.0.12 in production
mode, with checkinterval:
java.lang.NullPointerException
org.apache.jasper.JasperException: java.lang.NullPointerException
at
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:498)
at
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:386)
at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:330)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:741)
at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:231)
at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
at
org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher.java:712)
at
org.apache.catalina.core.ApplicationDispatcher.doInclude(ApplicationDispatcher.java:580)
at
org.apache.catalina.core.ApplicationDispatcher.include(ApplicationDispatcher.java:516)
at
org.apache.jasper.runtime.JspRuntimeLibrary.include(JspRuntimeLibrary.java:868)
This issue seems to have been introduced by bug 62603, where getServlet can now
return null.
getReloadInternal seems to return false without theServlet being properly
initialized.
It seems it can occurs if firstTime is false, reload is true and
ctxt.getRuntimeContext().isCompileCheckInProgress() is true.
--
You are receiving this mail because:
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org
[Bug 62792] Race condition NullpointerException in JspServletWrapper
Posted by bu...@apache.org.
https://bz.apache.org/bugzilla/show_bug.cgi?id=62792
Mark Thomas <ma...@apache.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|NEW |RESOLVED
Resolution|--- |DUPLICATE
--- Comment #3 from Mark Thomas <ma...@apache.org> ---
The problem is a little broader than described here. The duplicate has a full
description and the discussion of the proposed fix.
*** This bug has been marked as a duplicate of bug 62757 ***
--
You are receiving this mail because:
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org
[Bug 62792] Race condition NullpointerException in JspServletWrapper
Posted by bu...@apache.org.
https://bz.apache.org/bugzilla/show_bug.cgi?id=62792
--- Comment #1 from Julien Béti <ju...@beti.name> ---
Sorry, the caused-by part of the trace was missing:
Caused by: java.lang.NullPointerException: null
at
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:458)
... 74 common frames omitted
--
You are receiving this mail because:
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org
[Bug 62792] Race condition NullpointerException in JspServletWrapper
Posted by bu...@apache.org.
https://bz.apache.org/bugzilla/show_bug.cgi?id=62792
Julien Béti <ju...@beti.name> changed:
What |Removed |Added
----------------------------------------------------------------------------
Depends on| |62603
Referenced Bugs:
https://bz.apache.org/bugzilla/show_bug.cgi?id=62603
[Bug 62603] Changes in tag files are not reflected in the rendered view or they
end up with a java.lang.NoClassDefFoundError
--
You are receiving this mail because:
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org
[Bug 62792] Race condition NullpointerException in JspServletWrapper
Posted by bu...@apache.org.
https://bz.apache.org/bugzilla/show_bug.cgi?id=62792
--- Comment #2 from Julien Béti <ju...@beti.name> ---
I would suggest to keep the "if(reload)" outside the synchronized block, and
check again inside with "getReloadInternal()"
Something like
if(reload) {
synchronized (this) {
if(getReloadInternal()) {
//...
}
}
}
--
You are receiving this mail because:
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org