Mercurial > pidgin
changeset 12856:be1cd5952a48
[gaim-migrate @ 15207]
Avoid crashing when the account has no statuses (e.g. an account for which the prpl can't be found/loaded)
committer: Tailor Script <tailor@pidgin.im>
author | Daniel Atallah <daniel.atallah@gmail.com> |
---|---|
date | Fri, 13 Jan 2006 01:02:56 +0000 |
parents | f9401180115a |
children | e5f780a6137b |
files | src/gtksavedstatuses.c |
diffstat | 1 files changed, 6 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/src/gtksavedstatuses.c Thu Jan 12 21:30:59 2006 +0000 +++ b/src/gtksavedstatuses.c Fri Jan 13 01:02:56 2006 +0000 @@ -1278,7 +1278,12 @@ char *message = NULL; const char *name = NULL; - gtk_combo_box_get_active_iter(dialog->box, &iter); + if (!gtk_combo_box_get_active_iter(dialog->box, &iter)) { + gtk_widget_destroy(dialog->window); + g_free(dialog); + return; + } + gtk_tree_model_get(GTK_TREE_MODEL(dialog->model), &iter, SUBSTATUS_COLUMN_ACCOUNT, &account, SUBSTATUS_COLUMN_STATUS_ID, &id,