diff options
author | Peter Williams <peterw@ximian.com> | 2001-08-20 23:57:43 +0800 |
---|---|---|
committer | Peter Williams <peterw@src.gnome.org> | 2001-08-20 23:57:43 +0800 |
commit | 8534057ff57cc50024fd438e287370191d77b43a (patch) | |
tree | 0275302f708ce94286e569f1810c186105923a94 | |
parent | db79f8266e5055e6d5512016dfa518f71ce1a8cc (diff) | |
download | gsoc2013-evolution-8534057ff57cc50024fd438e287370191d77b43a.tar gsoc2013-evolution-8534057ff57cc50024fd438e287370191d77b43a.tar.gz gsoc2013-evolution-8534057ff57cc50024fd438e287370191d77b43a.tar.bz2 gsoc2013-evolution-8534057ff57cc50024fd438e287370191d77b43a.tar.lz gsoc2013-evolution-8534057ff57cc50024fd438e287370191d77b43a.tar.xz gsoc2013-evolution-8534057ff57cc50024fd438e287370191d77b43a.tar.zst gsoc2013-evolution-8534057ff57cc50024fd438e287370191d77b43a.zip |
Whoops, make sure that the account has a source before removing it or
2001-08-20 Peter Williams <peterw@ximian.com>
* mail-accounts.c (mail_able): Whoops, make sure that the account
has a source before removing it or what-have-you.
svn path=/trunk/; revision=12310
-rw-r--r-- | mail/ChangeLog | 3 | ||||
-rw-r--r-- | mail/mail-accounts.c | 10 |
2 files changed, 9 insertions, 4 deletions
diff --git a/mail/ChangeLog b/mail/ChangeLog index 73379f885a..301c02c8a8 100644 --- a/mail/ChangeLog +++ b/mail/ChangeLog @@ -1,5 +1,8 @@ 2001-08-20 Peter Williams <peterw@ximian.com> + * mail-accounts.c (mail_able): Whoops, make sure that the account + has a source before removing it or what-have-you. + * subscribe-dialog.c: Add a few comments. 2001-08-20 Damon Chaplin <damon@ximian.com> diff --git a/mail/mail-accounts.c b/mail/mail-accounts.c index 7a5eec6e19..efdaf2e13e 100644 --- a/mail/mail-accounts.c +++ b/mail/mail-accounts.c @@ -352,10 +352,12 @@ mail_able (GtkButton *button, gpointer data) account = gtk_clist_get_row_data (dialog->mail_accounts, row); account->source->enabled = !account->source->enabled; - if (account->source->enabled) - mail_load_storage_by_uri (dialog->shell, account->source->url, account->name); - else - mail_remove_storage_by_uri (account->source->url); + if (account->source && account->source->url) { + if (account->source->enabled) + mail_load_storage_by_uri (dialog->shell, account->source->url, account->name); + else + mail_remove_storage_by_uri (account->source->url); + } mail_autoreceive_setup (); mail_config_write (); |