cxf-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From serg...@apache.org
Subject cxf git commit: [CXf-6104] Case insensutive comparison of charset parameters
Date Fri, 14 Nov 2014 13:08:44 GMT
Repository: cxf
Updated Branches:
  refs/heads/master e21d8b48c -> d333c275e


[CXf-6104] Case insensutive comparison of charset parameters


Project: http://git-wip-us.apache.org/repos/asf/cxf/repo
Commit: http://git-wip-us.apache.org/repos/asf/cxf/commit/d333c275
Tree: http://git-wip-us.apache.org/repos/asf/cxf/tree/d333c275
Diff: http://git-wip-us.apache.org/repos/asf/cxf/diff/d333c275

Branch: refs/heads/master
Commit: d333c275e1dcbce56e59239f19a4db15c5a828dc
Parents: e21d8b4
Author: Sergey Beryozkin <sberyozkin@talend.com>
Authored: Fri Nov 14 13:08:30 2014 +0000
Committer: Sergey Beryozkin <sberyozkin@talend.com>
Committed: Fri Nov 14 13:08:30 2014 +0000

----------------------------------------------------------------------
 .../src/main/java/org/apache/cxf/jaxrs/utils/JAXRSUtils.java    | 5 +++++
 1 file changed, 5 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cxf/blob/d333c275/rt/frontend/jaxrs/src/main/java/org/apache/cxf/jaxrs/utils/JAXRSUtils.java
----------------------------------------------------------------------
diff --git a/rt/frontend/jaxrs/src/main/java/org/apache/cxf/jaxrs/utils/JAXRSUtils.java b/rt/frontend/jaxrs/src/main/java/org/apache/cxf/jaxrs/utils/JAXRSUtils.java
index d9b757d..61308b0 100644
--- a/rt/frontend/jaxrs/src/main/java/org/apache/cxf/jaxrs/utils/JAXRSUtils.java
+++ b/rt/frontend/jaxrs/src/main/java/org/apache/cxf/jaxrs/utils/JAXRSUtils.java
@@ -160,6 +160,7 @@ public final class JAXRSUtils {
     private static final String PATH_SEGMENT_SEP = "/";
     private static final String REPORT_FAULT_MESSAGE_PROPERTY = "org.apache.cxf.jaxrs.report-fault-message";
     private static final String NO_CONTENT_EXCEPTION = "javax.ws.rs.core.NoContentException";
+    private static final String HTTP_CHARSET_PARAM = "charset"; 
     
     private JAXRSUtils() {        
     }
@@ -1435,6 +1436,10 @@ public final class JAXRSUtils {
                     for (Map.Entry<String, String> entry : userType.getParameters().entrySet())
{
                         String value = requiredType.getParameters().get(entry.getKey());
                         if (value != null && !value.equals(entry.getValue())) {
+                            if (HTTP_CHARSET_PARAM.equals(entry.getKey()) 
+                                && value.equalsIgnoreCase(entry.getValue())) {
+                                continue;
+                            }
                             parametersMatched = false;
                             break;
                         }


Mime
View raw message