mirror of
https://github.com/bisq-network/bisq.git
synced 2024-11-19 09:52:23 +01:00
Add try catch for unlock call
This commit is contained in:
parent
bbacd09074
commit
b5db7fc557
@ -498,12 +498,14 @@ public class Connection implements MessageListener {
|
||||
log.error("Exception at shutdown. " + e.getMessage());
|
||||
e.printStackTrace();
|
||||
} finally {
|
||||
if (protoOutputStreamLock.isLocked())
|
||||
protoOutputStreamLock.unlock();
|
||||
try {
|
||||
if (protoOutputStreamLock.isLocked())
|
||||
protoOutputStreamLock.unlock();
|
||||
} catch (Throwable ignore) {
|
||||
}
|
||||
try {
|
||||
protoOutputStream.close();
|
||||
} catch (IOException e) {
|
||||
e.printStackTrace();
|
||||
} catch (Throwable ignore) {
|
||||
}
|
||||
MoreExecutors.shutdownAndAwaitTermination(singleThreadExecutor, 500, TimeUnit.MILLISECONDS);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user