hadoop-common-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From aengin...@apache.org
Subject [48/50] [abbrv] hadoop git commit: HADOOP-14272. Azure: WasbRemoteCallHelper should use String equals for comparison. Contributed by Santhosh G Nayak
Date Tue, 04 Apr 2017 19:57:12 GMT
HADOOP-14272. Azure: WasbRemoteCallHelper should use String equals for comparison. Contributed
by Santhosh G Nayak


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

Branch: refs/heads/HDFS-7240
Commit: 27a44b60c1a55cabbf1873bca62db4e321c901ca
Parents: 6eba792
Author: Mingliang Liu <liuml07@apache.org>
Authored: Tue Apr 4 11:03:59 2017 -0700
Committer: Mingliang Liu <liuml07@apache.org>
Committed: Tue Apr 4 11:03:59 2017 -0700

----------------------------------------------------------------------
 .../java/org/apache/hadoop/fs/azure/WasbRemoteCallHelper.java     | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/hadoop/blob/27a44b60/hadoop-tools/hadoop-azure/src/main/java/org/apache/hadoop/fs/azure/WasbRemoteCallHelper.java
----------------------------------------------------------------------
diff --git a/hadoop-tools/hadoop-azure/src/main/java/org/apache/hadoop/fs/azure/WasbRemoteCallHelper.java
b/hadoop-tools/hadoop-azure/src/main/java/org/apache/hadoop/fs/azure/WasbRemoteCallHelper.java
index 09ea084..b43e5ae 100644
--- a/hadoop-tools/hadoop-azure/src/main/java/org/apache/hadoop/fs/azure/WasbRemoteCallHelper.java
+++ b/hadoop-tools/hadoop-azure/src/main/java/org/apache/hadoop/fs/azure/WasbRemoteCallHelper.java
@@ -88,7 +88,8 @@ class WasbRemoteCallHelper {
       }
 
       Header contentTypeHeader = response.getFirstHeader("Content-Type");
-      if (contentTypeHeader == null || contentTypeHeader.getValue() != APPLICATION_JSON)
{
+      if (contentTypeHeader == null
+          || !APPLICATION_JSON.equals(contentTypeHeader.getValue())) {
         throw new WasbRemoteCallException(getRequest.getURI().toString() + ":" +
             "Content-Type mismatch: expected: " + APPLICATION_JSON +
             ", got " + ((contentTypeHeader!=null) ? contentTypeHeader.getValue() : "NULL")


---------------------------------------------------------------------
To unsubscribe, e-mail: common-commits-unsubscribe@hadoop.apache.org
For additional commands, e-mail: common-commits-help@hadoop.apache.org


Mime
View raw message