DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT <http://issues.apache.org/bugzilla/show_bug.cgi?id=30746>. ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND INSERTED IN THE BUG DATABASE.
http://issues.apache.org/bugzilla/show_bug.cgi?id=30746 request.getProtocol() can return null Summary: request.getProtocol() can return null Product: Tomcat 5 Version: 5.0.27 Platform: All URL: http://exo.sourceforge.net/forum/viewtopic.php?p=1835#18 35 OS/Version: All Status: NEW Severity: Normal Priority: Other Component: Servlet & JSP API AssignedTo: [EMAIL PROTECTED] ReportedBy: [EMAIL PROTECTED] CC: [EMAIL PROTECTED] Under some circumstances request.getProtocol() can return null. This breaks HttpServlet http://exo.sourceforge.net/forum/viewtopic.php?p=1835#1835 has the complete story of this bug, but briefly: 1) The Portlet Spec requires "The following methods of the HttpServletRequest must return null: getProtocol, getRemoteAddr, getRemoteHost, getRealPath, and getRequestURL." (from PLT.16.3.3 of the portlet spec). 2) When using the EXO portlet container with the spring framework portlet support Tomcat throws a NPE when including the view servlet in response to a POSTed request. While it is arguable if this is a bug in Tomcat or something else, it would be very helpful if Tomcat included NP checks when checking the protocol. ie: HttpServlet.doPost(HttpServletRequest req, HttpServletResponse resp) should do: if ((protocol != null) && protocol.endsWith("1.1")) {... and doGet(HttpServletRequest req, HttpServletResponse resp) should have the same thing --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]