From da4dc4d9c96fa2e7d42819efdbb729c4f82eb058 Mon Sep 17 00:00:00 2001 From: Robinson Date: Mon, 27 Jun 2022 01:45:10 +0200 Subject: [PATCH] Better handshake control during generic exceptions --- src/dorkbox/network/Client.kt | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/dorkbox/network/Client.kt b/src/dorkbox/network/Client.kt index 1abc4916..47a11737 100644 --- a/src/dorkbox/network/Client.kt +++ b/src/dorkbox/network/Client.kt @@ -467,7 +467,9 @@ open class Client( } } catch (e: Exception) { - logger.error(e) { "Un-recoverable error during handshake. Aborting." } + logger.error(e) { "[${handshake.connectKey}] : Un-recoverable error during handshake. Aborting." } + handshake.reset() + listenerManager.notifyError(e) throw e }