diff options
author | Matthias Sohn <matthias.sohn@sap.com> | 2019-04-18 18:42:45 +0200 |
---|---|---|
committer | Matthias Sohn <matthias.sohn@sap.com> | 2019-04-18 18:43:01 +0200 |
commit | 53014c0804e2aef8dce7ad535518b761114be6c7 (patch) | |
tree | bb9c2355739cf2fd218341576abb7fb629d5cd5a /org.eclipse.jgit/src/org/eclipse/jgit/errors/PackInvalidException.java | |
parent | f06de6b575f3f40ccd944ed2eb5c43d06666687f (diff) | |
parent | 551110b0e25190fec4d310e04d13d7bd19a7877a (diff) | |
download | jgit-53014c0804e2aef8dce7ad535518b761114be6c7.tar.gz jgit-53014c0804e2aef8dce7ad535518b761114be6c7.zip |
Merge branch 'stable-4.9' into stable-4.10
* stable-4.9:
Prepare 4.9.11-SNAPSHOT builds
JGit v4.9.10.201904181027-r
Prepare 4.7.10-SNAPSHOT builds
JGit v4.7.9.201904161809-r
Prepare 4.5.8-SNAPSHOT builds
JGit v4.5.7.201904151645-r
Remember the cause for invalidating a packfile
Fix API problem filters
Fix pack files scan when filesnapshot isn't modified
Change-Id: I94c9e6300b5f77b185ec6661fa76f0c74a5fc2a9
Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
Diffstat (limited to 'org.eclipse.jgit/src/org/eclipse/jgit/errors/PackInvalidException.java')
-rw-r--r-- | org.eclipse.jgit/src/org/eclipse/jgit/errors/PackInvalidException.java | 34 |
1 files changed, 32 insertions, 2 deletions
diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/errors/PackInvalidException.java b/org.eclipse.jgit/src/org/eclipse/jgit/errors/PackInvalidException.java index 9886e15dda..217d2097cb 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/errors/PackInvalidException.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/errors/PackInvalidException.java @@ -60,9 +60,24 @@ public class PackInvalidException extends IOException { * * @param path * path of the invalid pack file. + * @deprecated Use {@link #PackInvalidException(File, Throwable)}. */ + @Deprecated public PackInvalidException(final File path) { - this(path.getAbsolutePath()); + this(path, null); + } + + /** + * Construct a pack invalid error with cause. + * + * @param path + * path of the invalid pack file. + * @param cause + * cause of the pack file becoming invalid. + * @since 4.5.7 + */ + public PackInvalidException(final File path, Throwable cause) { + this(path.getAbsolutePath(), cause); } /** @@ -70,8 +85,23 @@ public class PackInvalidException extends IOException { * * @param path * path of the invalid pack file. + * @deprecated Use {@link #PackInvalidException(String, Throwable)}. */ + @Deprecated public PackInvalidException(final String path) { - super(MessageFormat.format(JGitText.get().packFileInvalid, path)); + this(path, null); + } + + /** + * Construct a pack invalid error with cause. + * + * @param path + * path of the invalid pack file. + * @param cause + * cause of the pack file becoming invalid. + * @since 4.5.7 + */ + public PackInvalidException(final String path, Throwable cause) { + super(MessageFormat.format(JGitText.get().packFileInvalid, path), cause); } } |