[gtk-list] the old gdk_window_set_user_data(NULL) patch
- From: Tim Janik <Tim Janik Hamburg Netsurf DE>
- To: |gtk mailing list <gtk-list redhat com>
- Subject: [gtk-list] the old gdk_window_set_user_data(NULL) patch
- Date: Mon, 12 May 1997 16:54:47 +0200 (CEST)
some while ago (23 Apr on gimp-developer) Kazuhiro Sasayama
posted a patch to reset the user_data of a GdkWindow to NULL
before destroying it.
this avoided spurious segmentation faults, but now there are
some spurious warnings:
> ** WARNING **: file gtkwidget.c: line 905 (gtk_widget_event): "widget != NULL"
> ** WARNING **: file gtkmain.c: line 817 (gtk_propagate_event): "widget != NULL"
instead of the segfaults.
if a GdkWindow is destroyed, but there are still events
in the queue referring to it, gtk_main_iteration() will
get that very event through gdk_event_get() and try to
extract the widget (gtk_get_event_widget()) from the
user_data of the GdkWindow wich is now NULL.
after this, gtk_widget_event() or gtk_propagate_event()
get called with the NULL as argument.
so i think gdk_event_get() should get changed to not
pass up events of a GdkWindow that has
((GdkWindowPrivate*)window)->destroyed set to TRUE.
something i don't understand is, why are there still some
calls to gdk_window_destroy() from variuous gtkwidgets that
doesn't call gdk_window_set_user_data(,NULL) first.
e.g.: gtkviewport.c, gtktext.c, gtkruler.c, gtkrange.c
and gtknotebook.c.
---
ciaoTJ
Tim.Janik@Hamburg.Netsurf.DE [signature: <CENS||ED>]
--
To unsubscribe: mail -s unsubscribe gtk-list-request@redhat.com < /dev/null
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]