tomcat-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From kkoli...@apache.org
Subject svn commit: r1195943 - /tomcat/trunk/java/org/apache/tomcat/util/http/Parameters.java
Date Tue, 01 Nov 2011 12:03:49 GMT
Author: kkolinko
Date: Tue Nov  1 12:03:49 2011
New Revision: 1195943

URL: http://svn.apache.org/viewvc?rev=1195943&view=rev
Log:
Followup to parameter parsing improvements.
urlDecode() sets bc.charset.
If decoding is skipped (because there is no '%' in the string) we shouldn't forget to set
the charset.

Modified:
    tomcat/trunk/java/org/apache/tomcat/util/http/Parameters.java

Modified: tomcat/trunk/java/org/apache/tomcat/util/http/Parameters.java
URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/tomcat/util/http/Parameters.java?rev=1195943&r1=1195942&r2=1195943&view=diff
==============================================================================
--- tomcat/trunk/java/org/apache/tomcat/util/http/Parameters.java (original)
+++ tomcat/trunk/java/org/apache/tomcat/util/http/Parameters.java Tue Nov  1 12:03:49 2011
@@ -319,12 +319,14 @@ public final class Parameters {
                 if (decodeName) {
                     name = urlDecode(tmpName, charset);
                 } else {
+                    tmpName.setCharset(charset);
                     name = tmpName.toString();
                 }
 
                 if (decodeValue) {
                     value = urlDecode(tmpValue, charset);
                 } else {
+                    tmpValue.setCharset(charset);
                     value = tmpValue.toString();
                 }
 



---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org


Mime
View raw message