You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@camel.apache.org by da...@apache.org on 2023/04/04 16:46:22 UTC
[camel] branch main updated: fix for the issue "assignment to a catch block parameter" (#9808)
This is an automated email from the ASF dual-hosted git repository.
davsclaus pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/camel.git
The following commit(s) were added to refs/heads/main by this push:
new 4ed1dd667f8 fix for the issue "assignment to a catch block parameter" (#9808)
4ed1dd667f8 is described below
commit 4ed1dd667f832a92f0ead4ead067c750e169b2bc
Author: dk2k <dk...@users.noreply.github.com>
AuthorDate: Tue Apr 4 19:46:14 2023 +0300
fix for the issue "assignment to a catch block parameter" (#9808)
Co-authored-by: dk2k <dk...@ya.ru>
---
.../java/org/apache/camel/component/cm/CMSenderOneMessageImpl.java | 7 ++++---
1 file changed, 4 insertions(+), 3 deletions(-)
diff --git a/components/camel-cm-sms/src/main/java/org/apache/camel/component/cm/CMSenderOneMessageImpl.java b/components/camel-cm-sms/src/main/java/org/apache/camel/component/cm/CMSenderOneMessageImpl.java
index f4634f05f6f..b684d9eaf6b 100644
--- a/components/camel-cm-sms/src/main/java/org/apache/camel/component/cm/CMSenderOneMessageImpl.java
+++ b/components/camel-cm-sms/src/main/java/org/apache/camel/component/cm/CMSenderOneMessageImpl.java
@@ -248,11 +248,12 @@ public class CMSenderOneMessageImpl implements CMSender {
} catch (final IOException io) {
throw new CMDirectException(io);
} catch (Exception t) {
- if (!(t instanceof CMDirectException)) {
+ Exception exception = t;
+ if (!(exception instanceof CMDirectException)) {
// Chain it
- t = new CMDirectException(t);
+ exception = new CMDirectException(exception);
}
- throw (CMDirectException) t;
+ throw (CMDirectException) exception;
}
}
}