(Throwable ex)
| 5862 | } |
| 5863 | |
| 5864 | void error(Throwable ex) { |
| 5865 | if (ex instanceof MessagingException && |
| 5866 | ("connection failure".equals(ex.getMessage()) || |
| 5867 | "Not connected".equals(ex.getMessage()) || // POP3 |
| 5868 | ex.getCause() instanceof SocketException || |
| 5869 | ex.getCause() instanceof ConnectionException)) |
| 5870 | recoverable = false; |
| 5871 | |
| 5872 | if (ex instanceof ConnectionException) |
| 5873 | // failed to create new store connection |
| 5874 | // BYE, Socket is closed |
| 5875 | recoverable = false; |
| 5876 | |
| 5877 | if (ex instanceof StoreClosedException || |
| 5878 | ex instanceof FolderClosedException || |
| 5879 | ex instanceof FolderNotFoundException) |
| 5880 | // Lost folder connection to server |
| 5881 | recoverable = false; |
| 5882 | |
| 5883 | if (ex instanceof IllegalStateException && ( |
| 5884 | "Not connected".equals(ex.getMessage()) || |
| 5885 | "This operation is not allowed on a closed folder".equals(ex.getMessage()))) |
| 5886 | recoverable = false; |
| 5887 | |
| 5888 | if (ex instanceof OperationCanceledException) |
| 5889 | recoverable = false; |
| 5890 | |
| 5891 | if (!recoverable) |
| 5892 | unrecoverable = ex; |
| 5893 | |
| 5894 | if (!backingoff) { |
| 5895 | thread.interrupt(); |
| 5896 | microWait(); |
| 5897 | } |
| 5898 | } |
| 5899 | |
| 5900 | void reset() { |
| 5901 | Thread.currentThread().interrupted(); // clear interrupted status |
no test coverage detected