Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMatthias Sohn2018-10-19 20:36:31 +0000
committerMatthias Sohn2018-10-19 20:36:31 +0000
commit566a5dcc21286b0944658d1559f1d8c61ca60cbd (patch)
tree40267d12fe1d32ff5e25e7e173dabd936aa0eeaa /org.eclipse.jgit.lfs.server
parentf282aaa137f326c360b87202620386c2dbb18949 (diff)
parentd6c587faef802663d615baaa6b388bf34f4e8ea7 (diff)
downloadjgit-566a5dcc21286b0944658d1559f1d8c61ca60cbd.tar.gz
jgit-566a5dcc21286b0944658d1559f1d8c61ca60cbd.tar.xz
jgit-566a5dcc21286b0944658d1559f1d8c61ca60cbd.zip
Merge branch 'stable-4.7' into stable-4.8
* stable-4.7: Prepare 4.7.7-SNAPSHOT builds JGit v4.7.6.201810191618-r Update API problem filter Fix file handle leak in ObjectDownloadListener.onWritePossible Replace Findbugs with Spotbugs in org.eclipse.jgit/pom.xml Replace FindBugs with SpotBugs Prepare 4.4.2-SNAPSHOT builds JGit v4.0.3.201509231615-r Change-Id: I783a083c0092a400f28f7977fbc4e556af88c8de
Diffstat (limited to 'org.eclipse.jgit.lfs.server')
-rw-r--r--org.eclipse.jgit.lfs.server/src/org/eclipse/jgit/lfs/server/fs/ObjectDownloadListener.java7
1 files changed, 6 insertions, 1 deletions
diff --git a/org.eclipse.jgit.lfs.server/src/org/eclipse/jgit/lfs/server/fs/ObjectDownloadListener.java b/org.eclipse.jgit.lfs.server/src/org/eclipse/jgit/lfs/server/fs/ObjectDownloadListener.java
index 2dc9493f3f..a76f7ef0d8 100644
--- a/org.eclipse.jgit.lfs.server/src/org/eclipse/jgit/lfs/server/fs/ObjectDownloadListener.java
+++ b/org.eclipse.jgit.lfs.server/src/org/eclipse/jgit/lfs/server/fs/ObjectDownloadListener.java
@@ -122,7 +122,7 @@ public class ObjectDownloadListener implements WriteListener {
} else {
buffer.flip();
}
- } catch(Throwable t) {
+ } catch (Throwable t) {
LOG.log(Level.SEVERE, t.getMessage(), t);
buffer = null;
} finally {
@@ -130,6 +130,11 @@ public class ObjectDownloadListener implements WriteListener {
outChannel.write(buffer);
} else {
try {
+ in.close();
+ } catch (IOException e) {
+ LOG.log(Level.SEVERE, e.getMessage(), e);
+ }
+ try {
out.close();
} finally {
context.complete();

Back to the top