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 2012/03/16 09:19:25 UTC
DO NOT REPLY [Bug 52926] New: NPE in processSocket
https://issues.apache.org/bugzilla/show_bug.cgi?id=52926
Bug #: 52926
Summary: NPE in processSocket
Product: Tomcat 7
Version: 7.0.25
Platform: PC
OS/Version: Linux
Status: NEW
Severity: critical
Priority: P2
Component: Connectors
AssignedTo: dev@tomcat.apache.org
ReportedBy: morten@ethlo.com
Classification: Unclassified
We have sporadic issues triggering 502 proxy errors using the NIO connector
behind Nginx, caused by dropped connections/end of streams in Tomcat. The
Tomcat log shows:
SEVERE: Error allocating socket processor
java.lang.NullPointerException
at org.apache.tomcat.util.net.NioEndpoint.processSocket(NioEndpoint.java:721)
at
org.apache.tomcat.util.net.NioEndpoint$Poller.cancelledKey(NioEndpoint.java:1048)
at org.apache.tomcat.util.net.NioEndpoint$Poller.timeout(NioEndpoint.java:1392)
at org.apache.tomcat.util.net.NioEndpoint$Poller.run(NioEndpoint.java:1174)
at java.lang.Thread.run(Thread.java:662)
Looking at the code in processSocket I see the line in NioEndpoint(721):
attachment.setCometNotify(false); //will get reset upon next reg
Attachment is fetched in line 720:
KeyAttachment attachment = (KeyAttachment)socket.getAttachment(false);
Looking at socket.getAttachement() method I see that this method is indeed
capable of returning null, but no null-check for this is done (although it is
in multiple other locations, so it seems inconsistent).
--
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- 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
DO NOT REPLY [Bug 52926] NPE in processSocket
Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=52926
Mark Thomas <ma...@apache.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|NEW |RESOLVED
Resolution| |FIXED
--- Comment #1 from Mark Thomas <ma...@apache.org> 2012-03-20 11:11:14 UTC ---
Thanks for the report. Fixed in trunk and 7.0.x and will be included in 7.0.27
onwards.
--
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- 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
DO NOT REPLY [Bug 52926] NPE in processSocket
Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=52926
Morten Haraldsen <mo...@ethlo.com> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |morten@ethlo.com
--
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- 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