hadoop-common-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From sur...@apache.org
Subject svn commit: r1422275 - in /hadoop/common/branches/branch-trunk-win/hadoop-common-project/hadoop-common: CHANGES.branch-trunk-win.txt src/main/java/org/apache/hadoop/fs/FileUtil.java src/main/java/org/apache/hadoop/fs/Path.java
Date Sat, 15 Dec 2012 15:21:50 GMT
Author: suresh
Date: Sat Dec 15 15:21:49 2012
New Revision: 1422275

URL: http://svn.apache.org/viewvc?rev=1422275&view=rev
Log:
HADOOP-9144. Fix findbugs warnings. Contribute by Chris Nauroth.

Modified:
    hadoop/common/branches/branch-trunk-win/hadoop-common-project/hadoop-common/CHANGES.branch-trunk-win.txt
    hadoop/common/branches/branch-trunk-win/hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/fs/FileUtil.java
    hadoop/common/branches/branch-trunk-win/hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/fs/Path.java

Modified: hadoop/common/branches/branch-trunk-win/hadoop-common-project/hadoop-common/CHANGES.branch-trunk-win.txt
URL: http://svn.apache.org/viewvc/hadoop/common/branches/branch-trunk-win/hadoop-common-project/hadoop-common/CHANGES.branch-trunk-win.txt?rev=1422275&r1=1422274&r2=1422275&view=diff
==============================================================================
--- hadoop/common/branches/branch-trunk-win/hadoop-common-project/hadoop-common/CHANGES.branch-trunk-win.txt
(original)
+++ hadoop/common/branches/branch-trunk-win/hadoop-common-project/hadoop-common/CHANGES.branch-trunk-win.txt
Sat Dec 15 15:21:49 2012
@@ -62,3 +62,5 @@ branch-trunk-win changes - unreleased
 
   HADOOP-9056. Build native library on Windows. (Chuan Liu, Arpit Agarwal via
   suresh)
+
+  HADOOP-9144. Fix findbugs warnings. (Chris Nauroth via suresh)

Modified: hadoop/common/branches/branch-trunk-win/hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/fs/FileUtil.java
URL: http://svn.apache.org/viewvc/hadoop/common/branches/branch-trunk-win/hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/fs/FileUtil.java?rev=1422275&r1=1422274&r2=1422275&view=diff
==============================================================================
--- hadoop/common/branches/branch-trunk-win/hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/fs/FileUtil.java
(original)
+++ hadoop/common/branches/branch-trunk-win/hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/fs/FileUtil.java
Sat Dec 15 15:21:49 2012
@@ -694,7 +694,7 @@ public class FileUtil {
     rv = f.setReadable(group.implies(FsAction.READ), false);
     checkReturnValue(rv, f, permission);
     if (group.implies(FsAction.READ) != user.implies(FsAction.READ)) {
-      f.setReadable(user.implies(FsAction.READ), true);
+      rv = f.setReadable(user.implies(FsAction.READ), true);
       checkReturnValue(rv, f, permission);
     }
 
@@ -702,7 +702,7 @@ public class FileUtil {
     rv = f.setWritable(group.implies(FsAction.WRITE), false);
     checkReturnValue(rv, f, permission);
     if (group.implies(FsAction.WRITE) != user.implies(FsAction.WRITE)) {
-      f.setWritable(user.implies(FsAction.WRITE), true);
+      rv = f.setWritable(user.implies(FsAction.WRITE), true);
       checkReturnValue(rv, f, permission);
     }
 
@@ -710,7 +710,7 @@ public class FileUtil {
     rv = f.setExecutable(group.implies(FsAction.EXECUTE), false);
     checkReturnValue(rv, f, permission);
     if (group.implies(FsAction.EXECUTE) != user.implies(FsAction.EXECUTE)) {
-      f.setExecutable(user.implies(FsAction.EXECUTE), true);
+      rv = f.setExecutable(user.implies(FsAction.EXECUTE), true);
       checkReturnValue(rv, f, permission);
     }
   }

Modified: hadoop/common/branches/branch-trunk-win/hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/fs/Path.java
URL: http://svn.apache.org/viewvc/hadoop/common/branches/branch-trunk-win/hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/fs/Path.java?rev=1422275&r1=1422274&r2=1422275&view=diff
==============================================================================
--- hadoop/common/branches/branch-trunk-win/hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/fs/Path.java
(original)
+++ hadoop/common/branches/branch-trunk-win/hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/fs/Path.java
Sat Dec 15 15:21:49 2012
@@ -202,8 +202,8 @@ public class Path implements Comparable 
     if (WINDOWS &&
         (hasWindowsDrive(path) ||
          (scheme == null) ||
-         (scheme == "") ||
-         (scheme == "file"))) {
+         (scheme.isEmpty()) ||
+         (scheme.equals("file")))) {
       path = StringUtils.replace(path, "\\", "/");
     }
     



Mime
View raw message