aboutsummaryrefslogtreecommitdiffstats
path: root/org.eclipse.jgit/src/org/eclipse/jgit/lib
diff options
context:
space:
mode:
authorJonathan Nieder <jrn@google.com>2018-10-09 15:29:00 -0700
committerJonathan Nieder <jrn@google.com>2018-10-09 15:52:54 -0700
commitc58362c1748abceacf35fc6b3d0d53125f7cdf71 (patch)
tree912fcd81d9aae134fd24f920bc7d77d0937c815f /org.eclipse.jgit/src/org/eclipse/jgit/lib
parent81b7f0e83595af162fe9950c6f2867b14901ec60 (diff)
downloadjgit-c58362c1748abceacf35fc6b3d0d53125f7cdf71.tar.gz
jgit-c58362c1748abceacf35fc6b3d0d53125f7cdf71.zip
Avoid using @Nullable to annotate arrays
As described in the javadoc for org.eclipse.jgit.annotations.Nullable: Warning: Please do not use this annotation on arrays. Different annotation processors treat `@Nullable Object[]` differently: some treat it as an array of nullable objects, for consistency with versions of `Nullable` defined with `@Target TYPE_USE`, while others treat it as a nullable array of objects. JGit therefore avoids using this annotation on arrays altogether. See the checker-framework manual[1] for details. [1] http://types.cs.washington.edu/checker-framework/current/checker-framework-manual.html#faq-array-syntax-meaning Change-Id: I14ffcf80adbb8145d797998de2f2fa6ab84c3ae3 Signed-off-by: Jonathan Nieder <jrn@google.com>
Diffstat (limited to 'org.eclipse.jgit/src/org/eclipse/jgit/lib')
-rw-r--r--org.eclipse.jgit/src/org/eclipse/jgit/lib/Config.java2
-rw-r--r--org.eclipse.jgit/src/org/eclipse/jgit/lib/Repository.java1
2 files changed, 0 insertions, 3 deletions
diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/lib/Config.java b/org.eclipse.jgit/src/org/eclipse/jgit/lib/Config.java
index 8558e3d0b2..4726975d07 100644
--- a/org.eclipse.jgit/src/org/eclipse/jgit/lib/Config.java
+++ b/org.eclipse.jgit/src/org/eclipse/jgit/lib/Config.java
@@ -62,7 +62,6 @@ import java.util.Set;
import java.util.concurrent.TimeUnit;
import java.util.concurrent.atomic.AtomicReference;
-import org.eclipse.jgit.annotations.Nullable;
import org.eclipse.jgit.errors.ConfigInvalidException;
import org.eclipse.jgit.events.ConfigChangedEvent;
import org.eclipse.jgit.events.ConfigChangedListener;
@@ -1158,7 +1157,6 @@ public class Config {
* if something went wrong while reading the config
* @since 4.10
*/
- @Nullable
protected byte[] readIncludedConfig(String relPath)
throws ConfigInvalidException {
return null;
diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/lib/Repository.java b/org.eclipse.jgit/src/org/eclipse/jgit/lib/Repository.java
index 2a2699f906..77d268a3bd 100644
--- a/org.eclipse.jgit/src/org/eclipse/jgit/lib/Repository.java
+++ b/org.eclipse.jgit/src/org/eclipse/jgit/lib/Repository.java
@@ -1981,7 +1981,6 @@ public abstract class Repository implements AutoCloseable {
* empty
* @throws IOException
*/
- @Nullable
private byte[] readGitDirectoryFile(String filename) throws IOException {
File file = new File(getDirectory(), filename);
try {