Mercurial > pidgin.yaz
diff pidgin/gtkblist.c @ 22662:84dc71e67a72
Fix a null pointer deref (hopefully). I haven't been able to consistently
recreate this, but I think this is the problem.
author | Daniel Atallah <daniel.atallah@gmail.com> |
---|---|
date | Wed, 16 Apr 2008 21:34:38 +0000 |
parents | 654f8386f4b3 |
children | 387071b0d4d4 |
line wrap: on
line diff
--- a/pidgin/gtkblist.c Wed Apr 16 07:25:47 2008 +0000 +++ b/pidgin/gtkblist.c Wed Apr 16 21:34:38 2008 +0000 @@ -4436,9 +4436,10 @@ } static gboolean -headline_click_callback(gpointer data) -{ - ((GSourceFunc)gtkblist->headline_callback)(gtkblist->headline_data); +headline_click_callback(gpointer unused) +{ + if (gtkblist->headline_callback) + ((GSourceFunc) gtkblist->headline_callback)(gtkblist->headline_data); reset_headline(gtkblist); return FALSE; } @@ -4448,7 +4449,7 @@ { gtk_widget_hide(gtkblist->headline_hbox); if (gtkblist->headline_callback && !headline_hover_close((int)event->x, (int)event->y)) - g_idle_add((GSourceFunc)headline_click_callback, gtkblist->headline_data); + g_idle_add(headline_click_callback, NULL); else { if (gtkblist->headline_destroy) gtkblist->headline_destroy(gtkblist->headline_data);