pull/189/head
M66B 4 years ago
parent f0f14f66e4
commit 2680dc697a

@ -47,6 +47,8 @@ import androidx.preference.PreferenceManager;
import com.sun.mail.gimap.GmailFolder; import com.sun.mail.gimap.GmailFolder;
import com.sun.mail.gimap.GmailMessage; import com.sun.mail.gimap.GmailMessage;
import com.sun.mail.iap.BadCommandException;
import com.sun.mail.iap.CommandFailedException;
import com.sun.mail.iap.ConnectionException; import com.sun.mail.iap.ConnectionException;
import com.sun.mail.iap.ProtocolException; import com.sun.mail.iap.ProtocolException;
import com.sun.mail.iap.Response; import com.sun.mail.iap.Response;
@ -464,12 +466,10 @@ class Core {
ex instanceof FileNotFoundException || ex instanceof FileNotFoundException ||
ex instanceof FolderNotFoundException || ex instanceof FolderNotFoundException ||
ex instanceof IllegalArgumentException || ex instanceof IllegalArgumentException ||
(ex instanceof IllegalStateException &&
EntityOperation.SYNC.equals(op.name) &&
"This operation is not allowed on a closed folder".equals(ex.getMessage())) ||
ex instanceof SQLiteConstraintException || ex instanceof SQLiteConstraintException ||
//ex.getCause() instanceof BadCommandException || // BAD (!ConnectionHelper.isIoError(ex) &&
//ex.getCause() instanceof CommandFailedException || // NO (ex.getCause() instanceof BadCommandException ||
ex.getCause() instanceof CommandFailedException /* NO */)) ||
MessageHelper.isRemoved(ex) || MessageHelper.isRemoved(ex) ||
EntityOperation.ATTACHMENT.equals(op.name) || EntityOperation.ATTACHMENT.equals(op.name) ||
(ConnectionHelper.isIoError(ex) && (ConnectionHelper.isIoError(ex) &&
@ -478,6 +478,7 @@ class Core {
// com.sun.mail.iap.BadCommandException: B13 BAD [TOOBIG] Message too large // com.sun.mail.iap.BadCommandException: B13 BAD [TOOBIG] Message too large
// com.sun.mail.iap.CommandFailedException: AY3 NO [CANNOT] Cannot APPEND to a SPAM folder // com.sun.mail.iap.CommandFailedException: AY3 NO [CANNOT] Cannot APPEND to a SPAM folder
// com.sun.mail.iap.CommandFailedException: B16 NO [ALERT] Cannot MOVE messages out of the Drafts folder // com.sun.mail.iap.CommandFailedException: B16 NO [ALERT] Cannot MOVE messages out of the Drafts folder
// com.sun.mail.iap.CommandFailedException: AV5 NO [OVERQUOTA] quota exceeded
// Drafts: javax.mail.FolderClosedException: * BYE Jakarta Mail Exception: // Drafts: javax.mail.FolderClosedException: * BYE Jakarta Mail Exception:
// javax.net.ssl.SSLException: Write error: ssl=0x8286cac0: I/O error during system call, Broken pipe // javax.net.ssl.SSLException: Write error: ssl=0x8286cac0: I/O error during system call, Broken pipe
// Drafts: * BYE Jakarta Mail Exception: java.io.IOException: Connection dropped by server? // Drafts: * BYE Jakarta Mail Exception: java.io.IOException: Connection dropped by server?
@ -486,7 +487,9 @@ class Core {
" folder=" + folder.id + ":" + folder.name + " folder=" + folder.id + ":" + folder.name +
" message=" + (message == null ? null : message.id + ":" + message.subject) + " message=" + (message == null ? null : message.id + ":" + message.subject) +
" reason=" + Log.formatThrowable(ex, false)); " reason=" + Log.formatThrowable(ex, false));
if (op.tries > 1) if (op.tries > 1 ||
ex.getCause() instanceof BadCommandException ||
ex.getCause() instanceof CommandFailedException)
Log.e(new Throwable(msg, ex)); Log.e(new Throwable(msg, ex));
try { try {

Loading…
Cancel
Save