Suppress close exception instead

This commit is contained in:
Mygod
2020-11-13 05:30:20 +08:00
parent 795caee54d
commit aa9cc98581

View File

@@ -39,7 +39,7 @@ abstract class RootSession {
try {
server.close()
} catch (eClose: Throwable) {
throw eClose.apply { addSuppressed(e) }
e.addSuppressed(eClose)
}
throw e
}