diff options
Diffstat (limited to 'org.eclipse.egit.ui/src/org/eclipse/egit/ui/internal/history/CommitGraphTable.java')
-rw-r--r-- | org.eclipse.egit.ui/src/org/eclipse/egit/ui/internal/history/CommitGraphTable.java | 7 |
1 files changed, 2 insertions, 5 deletions
diff --git a/org.eclipse.egit.ui/src/org/eclipse/egit/ui/internal/history/CommitGraphTable.java b/org.eclipse.egit.ui/src/org/eclipse/egit/ui/internal/history/CommitGraphTable.java index 8cc31e5d18..b5b55e0abb 100644 --- a/org.eclipse.egit.ui/src/org/eclipse/egit/ui/internal/history/CommitGraphTable.java +++ b/org.eclipse.egit.ui/src/org/eclipse/egit/ui/internal/history/CommitGraphTable.java @@ -741,12 +741,9 @@ class CommitGraphTable { private void writeToFile(final String fileName, String content) throws IOException { - Writer output = new BufferedWriter(new OutputStreamWriter( - new FileOutputStream(fileName), UTF_8)); - try { + try (Writer output = new BufferedWriter(new OutputStreamWriter( + new FileOutputStream(fileName), UTF_8))) { output.write(content); - } finally { - output.close(); } } } |