diff options
author | David Pursehouse <david.pursehouse@gmail.com> | 2019-06-22 18:47:43 +0900 |
---|---|---|
committer | Matthias Sohn <matthias.sohn@sap.com> | 2019-08-08 14:28:27 +0200 |
commit | 72ae0892066fb4875136cf77c624194e394c0856 (patch) | |
tree | 5326dcf601d141d45553132248e8b224e73812ef /org.eclipse.jgit/src/org/eclipse/jgit/revwalk/FooterLine.java | |
parent | aefb11298c36960c4ae49fa830c8a93f1171f52f (diff) | |
download | jgit-72ae0892066fb4875136cf77c624194e394c0856.tar.gz jgit-72ae0892066fb4875136cf77c624194e394c0856.zip |
Fix NarrowingCompoundAssignment warnings from Error Prone
Error Prone reports:
[NarrowingCompoundAssignment] Compound assignments from long to int
hide lossy casts
and
[NarrowingCompoundAssignment] Compound assignments from int to byte
hide lossy casts
See https://errorprone.info/bugpattern/NarrowingCompoundAssignment
Fix the warnings by adding explicit casts or changing types as
necessary.
Now that all occurrences of the warning are fixed, increase its
severity to ERROR.
Change-Id: Idb3670e6047b146ae37daee07212ff9455512623
Signed-off-by: David Pursehouse <david.pursehouse@gmail.com>
Diffstat (limited to 'org.eclipse.jgit/src/org/eclipse/jgit/revwalk/FooterLine.java')
-rw-r--r-- | org.eclipse.jgit/src/org/eclipse/jgit/revwalk/FooterLine.java | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/revwalk/FooterLine.java b/org.eclipse.jgit/src/org/eclipse/jgit/revwalk/FooterLine.java index d6fed66702..84b6d2e481 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/revwalk/FooterLine.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/revwalk/FooterLine.java @@ -95,7 +95,7 @@ public final class FooterLine { for (int kPtr = 0; kPtr < len;) { byte b = buffer[bPtr++]; if ('A' <= b && b <= 'Z') - b += 'a' - 'A'; + b += (byte) ('a' - 'A'); if (b != kRaw[kPtr++]) return false; } |