Mercurial > pidgin.yaz
comparison src/gtkblist.c @ 13880:b869ab32cccc
[gaim-migrate @ 16358]
Fix an assertion failure when adding a buddy to your buddy list and
you have an open conversation with that buddy and you don't have
an icon for them.
committer: Tailor Script <tailor@pidgin.im>
author | Mark Doliner <mark@kingant.net> |
---|---|
date | Tue, 27 Jun 2006 16:28:20 +0000 |
parents | d1fdde7cfc0a |
children | 085b15c33ca4 |
comparison
equal
deleted
inserted
replaced
13879:b5ff22440a5b | 13880:b869ab32cccc |
---|---|
4459 | 4459 |
4460 static void | 4460 static void |
4461 add_buddy_cb(GtkWidget *w, int resp, GaimGtkAddBuddyData *data) | 4461 add_buddy_cb(GtkWidget *w, int resp, GaimGtkAddBuddyData *data) |
4462 { | 4462 { |
4463 const char *grp, *who, *whoalias; | 4463 const char *grp, *who, *whoalias; |
4464 GaimGroup *g; | |
4465 GaimBuddy *b; | |
4464 GaimConversation *c; | 4466 GaimConversation *c; |
4465 GaimBuddy *b; | 4467 GaimBuddyIcon *icon; |
4466 GaimGroup *g; | |
4467 | 4468 |
4468 if (resp == GTK_RESPONSE_OK) | 4469 if (resp == GTK_RESPONSE_OK) |
4469 { | 4470 { |
4470 who = gtk_entry_get_text(GTK_ENTRY(data->entry)); | 4471 who = gtk_entry_get_text(GTK_ENTRY(data->entry)); |
4471 grp = gtk_entry_get_text(GTK_ENTRY(GTK_COMBO(data->combo)->entry)); | 4472 grp = gtk_entry_get_text(GTK_ENTRY(GTK_COMBO(data->combo)->entry)); |
4498 * Or something. --Mark | 4499 * Or something. --Mark |
4499 */ | 4500 */ |
4500 | 4501 |
4501 c = gaim_find_conversation_with_account(GAIM_CONV_TYPE_IM, who, data->account); | 4502 c = gaim_find_conversation_with_account(GAIM_CONV_TYPE_IM, who, data->account); |
4502 if (c != NULL) { | 4503 if (c != NULL) { |
4503 gaim_buddy_icon_update(gaim_conv_im_get_icon(GAIM_CONV_IM(c))); | 4504 icon = gaim_conv_im_get_icon(GAIM_CONV_IM(c)); |
4505 if (icon != NULL) | |
4506 gaim_buddy_icon_update(icon); | |
4504 } | 4507 } |
4505 } | 4508 } |
4506 | 4509 |
4507 gtk_widget_destroy(data->window); | 4510 gtk_widget_destroy(data->window); |
4508 } | 4511 } |