summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/main/clojure/org/gnu/clojure/gnunet/tcp.clj9
1 files changed, 6 insertions, 3 deletions
diff --git a/src/main/clojure/org/gnu/clojure/gnunet/tcp.clj b/src/main/clojure/org/gnu/clojure/gnunet/tcp.clj
index 430dad8..1246c6e 100644
--- a/src/main/clojure/org/gnu/clojure/gnunet/tcp.clj
+++ b/src/main/clojure/org/gnu/clojure/gnunet/tcp.clj
@@ -45,13 +45,16 @@
(defn update-selection-key-async!
([peer selection-key ops]
(.add (:selector-continuations-queue peer)
- #(.interestOps selection-key ops))
+ #(try
+ (.interestOps selection-key ops)
+ (catch Exception e)))
(.wakeup (:selector peer)))
([peer selection-key ops attachment]
(.add (:selector-continuations-queue peer)
- #(do
+ #(try
(.interestOps selection-key ops)
- (.attach selection-key attachment)))
+ (.attach selection-key attachment)
+ (catch Exception e)))
(.wakeup (:selector peer))))
(defn admit-tcp-message!