GNOME Bugzilla – Bug 141020
gtkmain.c: multiple warnings about deferencing type-punned pointer breaks strict aliasing rules
Last modified: 2008-03-27 22:07:27 UTC
gtkmain.c functions that generate this warning: load_module - happens because g_module_symbol is not passed a gpointer address. Dealt with this by creating a new gpointer variable pmodinit_func, then copied the address of the function pointer modinit_func into it. pmodinit_func is then passed to g_module_symbol. rewrite_event_for_grabs - gdk_window_get_user_data expects 2nd parameter to be a gpointer*, instead is getting a GtkWidget*. Did much the same thing as with load_module fix. gtk_get_event_widget - same reason as for rewrite_event_for_grabs, it calls gdk_window_get_user_data and passes it a GtkWidget* as second parameter. Same fix.
Created attachment 27043 [details] [review] Proposed patch for gtkmain.c
is this still relevant for the latest gtk+?
chris, can you please answer christian's question? thanks in advance!
Resolving as obsolete, patch doesn't apply anymore and the relevant code has disappeared from gtkmain.c since the patch was written.