Mercurial > pidgin.yaz
diff src/gtkutils.c @ 13469:689f652480f7
[gaim-migrate @ 15845]
For cursor setting, it's the widget's window being NULL that's the problem. Passing in a NULL widget wouldn't make any sense. So, I've clarified the checks here. This fixes a couple assertion failure regressions.
committer: Tailor Script <tailor@pidgin.im>
author | Richard Laager <rlaager@wiktel.com> |
---|---|
date | Wed, 08 Mar 2006 22:03:22 +0000 |
parents | ffd724befbf8 |
children | 743e38a3182b |
line wrap: on
line diff
--- a/src/gtkutils.c Wed Mar 08 21:37:43 2006 +0000 +++ b/src/gtkutils.c Wed Mar 08 22:03:22 2006 +0000 @@ -2184,7 +2184,8 @@ { GdkCursor *cursor; - if (widget == NULL) + g_return_if_fail(widget != NULL); + if (widget->window == NULL) return; cursor = gdk_cursor_new(GDK_WATCH); @@ -2200,7 +2201,8 @@ void gaim_gtk_clear_cursor(GtkWidget *widget) { - if (widget == NULL) + g_return_if_fail(widget != NULL); + if (widget->window == NULL) return; gdk_window_set_cursor(widget->window, NULL);