remm 2002/07/11 01:33:23 Modified: coyote/src/java/org/apache/coyote/tomcat4 CoyoteRequest.java Log: - Port code from the old HTTP connector: parse out ";charset=...". - Should fix bug 10674. Revision Changes Path 1.25 +14 -6 jakarta-tomcat-connectors/coyote/src/java/org/apache/coyote/tomcat4/CoyoteRequest.java Index: CoyoteRequest.java =================================================================== RCS file: /home/cvs/jakarta-tomcat-connectors/coyote/src/java/org/apache/coyote/tomcat4/CoyoteRequest.java,v retrieving revision 1.24 retrieving revision 1.25 diff -u -r1.24 -r1.25 --- CoyoteRequest.java 3 Jul 2002 17:43:24 -0000 1.24 +++ CoyoteRequest.java 11 Jul 2002 08:33:22 -0000 1.25 @@ -1925,7 +1925,16 @@ if (!getMethod().equalsIgnoreCase("POST")) return; - if (!("application/x-www-form-urlencoded".equals(getContentType()))) + String contentType = getContentType(); + if (contentType == null) + contentType = ""; + int semicolon = contentType.indexOf(';'); + if (semicolon >= 0) { + contentType = contentType.substring(0, semicolon).trim(); + } else { + contentType = contentType.trim(); + } + if (!("application/x-www-form-urlencoded".equals(contentType))) return; int len = getContentLength(); @@ -1943,7 +1952,6 @@ readPostBody(formData, len); parameters.processParameters(formData, 0, len); } catch (Throwable t) { - t.printStackTrace(); // TEMP ; // Ignore } }
-- To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]> For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>