Permalink
Browse files

wrapping exception on stop() and destroy() in catch

  • Loading branch information...
1 parent adc5149 commit e2a81c963e80171e16ac85c0f3e5d635c935f493 Bela Ban committed Feb 11, 2011
Showing with 12 additions and 2 deletions.
  1. +12 −2 src/org/jgroups/stack/ProtocolStack.java
@@ -722,8 +722,18 @@ public Protocol removeProtocol(String prot_name) throws Exception {
below.setUpProtocol(above);
prot.setUpProtocol(null);
prot.setDownProtocol(null);
- prot.stop();
- prot.destroy();
+ try {
+ prot.stop();
+ }
+ catch(Throwable t) {
+ log.error("failed stopping " + prot.getName() + ": " + t);
+ }
+ try {
+ prot.destroy();
+ }
+ catch(Throwable t) {
+ log.error("failed destroying " + prot.getName() + ": " + t);
+ }
return prot;
}

0 comments on commit e2a81c9

Please sign in to comment.