1
0
Fork 0
mirror of https://github.com/M66B/FairEmail.git synced 2024-12-27 18:27:43 +00:00

I/O exceptions can happen

This commit is contained in:
M66B 2022-06-08 16:24:39 +02:00
parent d2d6ac8ab6
commit beb1ce0e05

View file

@ -486,10 +486,15 @@ class Protocol {
doAuth(host, authzid, user, passwd);
} catch (IOException ex) { // should never happen, ignore
logger.log(Level.FINE, "AUTH " + mech + " failed", ex);
thrown = ex;
} catch (Throwable t) { // crypto can't be initialized?
logger.log(Level.FINE, "AUTH " + mech + " failed", t);
thrown = t;
} finally {
if (thrown instanceof IOException) {
close();
throw (IOException) thrown;
}
if (noauthdebug && isTracing())
logger.fine("AUTH " + mech + " " +
(resp.ok ? "succeeded" : "failed"));