]> source.dussan.org Git - jgit.git/commitdiff
Remove 4 unboxed warnings 01/5901/2
authorKevin Sawicki <kevin@github.com>
Wed, 9 May 2012 15:45:08 +0000 (08:45 -0700)
committerMatthias Sohn <matthias.sohn@sap.com>
Wed, 9 May 2012 22:32:27 +0000 (00:32 +0200)
Use Integer.intValue to explicitly convert to an int

Change-Id: I1135ed01af4e274b26d6b07d1a50f48ef0a30d91
Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
org.eclipse.jgit/src/org/eclipse/jgit/revplot/PlotCommitList.java
org.eclipse.jgit/src/org/eclipse/jgit/transport/TransportSftp.java

index 3ad56d1846e0b6ab02018108bb47320fb2462a14..382d162439ba23b7fbf5e88df3590963c4cc40c7 100644 (file)
@@ -225,8 +225,8 @@ public class PlotCommitList<L extends PlotLane> extends
                if (blockedPositions.get(commit.lane.getPosition())) {
                        int newPos = -1;
                        for (Integer pos : freePositions)
-                               if (!blockedPositions.get(pos)) {
-                                       newPos = pos;
+                               if (!blockedPositions.get(pos.intValue())) {
+                                       newPos = pos.intValue();
                                        break;
                                }
                        if (newPos == -1)
index dec6a4f40527a0b182a1eabcf595f31d47875200..dbb6c7ce0bb93244f4b840a4785ccc8988f33014 100644 (file)
@@ -248,7 +248,8 @@ public class TransportSftp extends SshTransport implements WalkTransport {
 
                                Collections.sort(packs, new Comparator<String>() {
                                        public int compare(final String o1, final String o2) {
-                                               return mtimes.get(o2) - mtimes.get(o1);
+                                               return mtimes.get(o2).intValue()
+                                                               - mtimes.get(o1).intValue();
                                        }
                                });
                        } catch (SftpException je) {