parent
c3629be043
commit
5dde584f1f
3 changed files with 10 additions and 1 deletions
|
|
@ -400,6 +400,8 @@ public abstract class Geary.ClientService : BaseObject, Logging.Source {
|
|||
this.last_error = error;
|
||||
this.current_status = CONNECTION_FAILED;
|
||||
connection_error(error);
|
||||
// Network error, so try to connect again
|
||||
on_connectivity_change();
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
|||
|
|
@ -546,6 +546,12 @@ public class Geary.Imap.ClientService : Geary.ClientService {
|
|||
session,
|
||||
(obj, res) => { this.remove_session_async.end(res); }
|
||||
);
|
||||
if (session.disconnected == ClientSession.DisconnectReason.REMOTE_ERROR) {
|
||||
Geary.ErrorContext context = new Geary.ErrorContext(
|
||||
new GLib.IOError.NOT_CONNECTED("Session disconnected, remote error")
|
||||
);
|
||||
notify_connection_failed(context);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -189,8 +189,9 @@ public class Geary.ConnectivityManager : BaseObject {
|
|||
// localhost. (This is a Linux program, after all...)
|
||||
debug("Network changed: %s",
|
||||
some_available ? "some available" : "none available");
|
||||
|
||||
cancel_check();
|
||||
if (some_available) {
|
||||
cancel_check();
|
||||
this.delayed_check.start_ms(CHECK_SOON);
|
||||
} else {
|
||||
// None available, so definitely not reachable.
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue