]> source.dussan.org Git - jgit.git/commitdiff
FS_POSIX: Fix reference comparison of Boolean.FALSE 74/143574/3
authorDavid Pursehouse <david.pursehouse@gmail.com>
Sat, 8 Jun 2019 05:54:19 +0000 (14:54 +0900)
committerDavid Pursehouse <david.pursehouse@gmail.com>
Tue, 11 Jun 2019 00:22:17 +0000 (09:22 +0900)
Change-Id: Ic205d017b365ea85983d0b0d9d033fcf7e6bf6ab
Signed-off-by: David Pursehouse <david.pursehouse@gmail.com>
org.eclipse.jgit/src/org/eclipse/jgit/util/FS_POSIX.java

index 588855b1f8d77f916665825ee042d4a166bc0fa4..faef9fd0f4aa233cd511629b5d47ef6688d5c13a 100644 (file)
@@ -400,7 +400,7 @@ public class FS_POSIX extends FS {
                try {
                        Boolean canLink = CAN_HARD_LINK.computeIfAbsent(store,
                                        s -> Boolean.TRUE);
-                       if (canLink == Boolean.FALSE) {
+                       if (Boolean.FALSE.equals(canLink)) {
                                return true;
                        }
                        link = Files.createLink(
@@ -466,7 +466,7 @@ public class FS_POSIX extends FS {
                try {
                        Boolean canLink = CAN_HARD_LINK.computeIfAbsent(store,
                                        s -> Boolean.TRUE);
-                       if (canLink == Boolean.FALSE) {
+                       if (Boolean.FALSE.equals(canLink)) {
                                return token(true, null);
                        }
                        link = Files.createLink(Paths.get(uniqueLinkPath(file)), path);