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:11:05 GMT
Repository: cxf
Updated Branches:
  refs/heads/2.7.x-fixes 8c34d25a2 -> f39223409


[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/f3922340
Tree: http://git-wip-us.apache.org/repos/asf/cxf/tree/f3922340
Diff: http://git-wip-us.apache.org/repos/asf/cxf/diff/f3922340

Branch: refs/heads/2.7.x-fixes
Commit: f39223409013ee0af6bfab4b3563ccc76d319c0d
Parents: 8c34d25
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:10:42 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/f3922340/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 d5c9337..f7fb8b1 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
@@ -154,6 +154,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() {        
     }
@@ -1370,6 +1371,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