Repository: camel Updated Branches: refs/heads/master ebb8f5ccc -> 1ba5a6bc3
Fixed CS Project: http://git-wip-us.apache.org/repos/asf/camel/repo Commit: http://git-wip-us.apache.org/repos/asf/camel/commit/0375fb18 Tree: http://git-wip-us.apache.org/repos/asf/camel/tree/0375fb18 Diff: http://git-wip-us.apache.org/repos/asf/camel/diff/0375fb18 Branch: refs/heads/master Commit: 0375fb18502fed7cf89f384aadf96fda4f4aa114 Parents: ebb8f5c Author: Claus Ibsen <davscl...@apache.org> Authored: Mon Mar 2 09:54:39 2015 +0100 Committer: Claus Ibsen <davscl...@apache.org> Committed: Mon Mar 2 09:54:39 2015 +0100 ---------------------------------------------------------------------- .../org/apache/camel/component/exec/ExecJava8IssueTest.java | 7 +++++-- .../main/java/org/apache/camel/component/mail/MailSorter.java | 6 +++--- 2 files changed, 8 insertions(+), 5 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/camel/blob/0375fb18/components/camel-exec/src/test/java/org/apache/camel/component/exec/ExecJava8IssueTest.java ---------------------------------------------------------------------- diff --git a/components/camel-exec/src/test/java/org/apache/camel/component/exec/ExecJava8IssueTest.java b/components/camel-exec/src/test/java/org/apache/camel/component/exec/ExecJava8IssueTest.java index 5fa78d4..97aa00e 100644 --- a/components/camel-exec/src/test/java/org/apache/camel/component/exec/ExecJava8IssueTest.java +++ b/components/camel-exec/src/test/java/org/apache/camel/component/exec/ExecJava8IssueTest.java @@ -103,10 +103,13 @@ public class ExecJava8IssueTest extends Assert { * Creates a script which will append " world" to a file */ private void writeScript(File script) throws IOException { - try (FileWriter fw = new FileWriter(script); - PrintWriter pw = new PrintWriter(fw)) { + FileWriter fw = new FileWriter(script); + try { + PrintWriter pw = new PrintWriter(fw); String s = "echo \" world\" >> $1"; pw.print(s); + } finally { + fw.close(); } } http://git-wip-us.apache.org/repos/asf/camel/blob/0375fb18/components/camel-mail/src/main/java/org/apache/camel/component/mail/MailSorter.java ---------------------------------------------------------------------- diff --git a/components/camel-mail/src/main/java/org/apache/camel/component/mail/MailSorter.java b/components/camel-mail/src/main/java/org/apache/camel/component/mail/MailSorter.java index e5c91c3..27ff8d9 100644 --- a/components/camel-mail/src/main/java/org/apache/camel/component/mail/MailSorter.java +++ b/components/camel-mail/src/main/java/org/apache/camel/component/mail/MailSorter.java @@ -53,14 +53,14 @@ public final class MailSorter { } /** - * Compute the potentially descendingd sort terms from the input list + * Compute the potentially descending sort terms from the input list * * @param sortTerm Input list * @return Sort terms list including if the respective sort should be sorted in descending order */ private static List<SortTermWithDescending> getSortTermsWithDescending(SortTerm[] sortTerm) { - // List of reversable sort terms. If the boolean is true the respective sort term is descendingd - final List<SortTermWithDescending> sortTermsWithDescending = new ArrayList<>(sortTerm.length); + // List of reversable sort terms. If the boolean is true the respective sort term is descending + final List<SortTermWithDescending> sortTermsWithDescending = new ArrayList<SortTermWithDescending>(sortTerm.length); // Descending next item in input because the last item was a "descending" boolean descendingNext = false; for (SortTerm term : sortTerm) {