GNOME Bugzilla – Bug 690271
gtk+ 2.24.14 on OS X: pressing create folder button in file chooser dialog results in crash
Last modified: 2012-12-17 21:24:48 UTC
Created attachment 231632 [details] crash report Installed gtk2 using macports with quartz backend enabled. I can reproduce this crash using included gtk-demo - pickers code demo, open selection dialog (Other...) for last input field, select home folder (just to be sure), press "create folder" button. I get the following backtrace (full crash report attached): Thread 0 Crashed:: Dispatch queue: com.apple.main-thread 0 libobjc.A.dylib 0x00007fff8f4a4750 objc_msgSend_vtable14 + 16 1 com.apple.AppKit 0x00007fff9393b4cf -[_NSPasteboardOwnersCollection _handleOwnershipChange] + 179 2 com.apple.AppKit 0x00007fff9393b8a6 _NSPasteboardReportChangedOwner + 45 3 com.apple.AppKit 0x00007fff9393ee16 -[NSPasteboard declareTypes:owner:] + 51 4 libgtk-quartz-2.0.0.dylib 0x00000001002e804b gtk_clipboard_set_contents + 235 5 libgtk-quartz-2.0.0.dylib 0x00000001002e8266 gtk_clipboard_set_with_owner + 230 6 libgtk-quartz-2.0.0.dylib 0x00000001001476e7 gtk_entry_update_primary_selection + 135 7 libgtk-quartz-2.0.0.dylib 0x000000010014b479 gtk_entry_grab_focus + 89 8 libgobject-2.0.0.dylib 0x0000000100a96a35 _g_closure_invoke_va + 309 9 libgobject-2.0.0.dylib 0x0000000100aa70d8 g_signal_emit_valist + 1352 10 libgobject-2.0.0.dylib 0x0000000100aa7d24 g_signal_emit + 116 11 libgtk-quartz-2.0.0.dylib 0x00000001002d2aec gtk_widget_grab_focus + 124 12 libgtk-quartz-2.0.0.dylib 0x00000001002afba5 gtk_tree_view_real_start_editing + 213 13 libgtk-quartz-2.0.0.dylib 0x00000001002ac1f3 gtk_tree_view_start_editing + 579 14 libgtk-quartz-2.0.0.dylib 0x000000010016a7c4 new_folder_button_clicked + 164 15 libgobject-2.0.0.dylib 0x0000000100a96a35 _g_closure_invoke_va + 309 16 libgobject-2.0.0.dylib 0x0000000100aa70d8 g_signal_emit_valist + 1352 17 libgobject-2.0.0.dylib 0x0000000100aa7d24 g_signal_emit + 116 18 libgtk-quartz-2.0.0.dylib 0x000000010011147f gtk_real_button_released + 127 19 libgobject-2.0.0.dylib 0x0000000100a96a35 _g_closure_invoke_va + 309 20 libgobject-2.0.0.dylib 0x0000000100aa70d8 g_signal_emit_valist + 1352 21 libgobject-2.0.0.dylib 0x0000000100aa7d24 g_signal_emit + 116 22 libgtk-quartz-2.0.0.dylib 0x00000001001110d3 gtk_button_button_release + 99 23 libgtk-quartz-2.0.0.dylib 0x00000001001bc0cf _gtk_marshal_BOOLEAN__BOXED + 159 24 libgobject-2.0.0.dylib 0x0000000100a96bc4 g_closure_invoke + 308 25 libgobject-2.0.0.dylib 0x0000000100aa683a signal_emit_unlocked_R + 2218 26 libgobject-2.0.0.dylib 0x0000000100aa77f8 g_signal_emit_valist + 3176 27 libgobject-2.0.0.dylib 0x0000000100aa7d24 g_signal_emit + 116 28 libgtk-quartz-2.0.0.dylib 0x00000001002d1ffc gtk_widget_event_internal + 620 29 libgtk-quartz-2.0.0.dylib 0x00000001001ba16f gtk_propagate_event + 383 30 libgtk-quartz-2.0.0.dylib 0x00000001001b9dce gtk_main_do_event + 1278 31 libgdk-quartz-2.0.0.dylib 0x00000001000765ea gdk_event_dispatch + 170 32 libglib-2.0.0.dylib 0x0000000100b238f8 g_main_context_dispatch + 328 33 libglib-2.0.0.dylib 0x0000000100b25a0e g_main_context_iterate + 510 34 libglib-2.0.0.dylib 0x0000000100b26faf g_main_loop_run + 287 35 libgtk-quartz-2.0.0.dylib 0x00000001001b95ef gtk_main + 191 36 gtk-demo 0x000000010001a59f main + 1583 37 gtk-demo 0x0000000100008674 start + 52
This problem has been fixed in our software repository. The fix will go into the next software release. Thank you for your bug report. http://git.gnome.org/browse/gtk+/commit/gtk/gtkclipboard-quartz.c?h=gtk-2-24&id=4a8df7a33c298d22bf78b947d0e861fc03ec70e1
With that fix applied compilation fails with these errors: gtkclipboard-quartz.c:373:14: error: instance variable 'setting_same_owner' is protected owner->setting_same_owner = TRUE; ^ gtkclipboard-quartz.c:376:14: error: instance variable 'setting_same_owner' is protected owner->setting_same_owner = FALSE; ^ 2 errors generated. I'll attach a patch to make this work.
Created attachment 231756 [details] [review] patch for bugfix
Thanks for the patch, I wonder why I didn't see any warning there. Pushed to gtk-2-24, gtk-3-6 and master: commit 597dc649e1f771ed7f4a01e46116909dfc813b21 Author: Michael Natterer <mitch@gimp.org> Date: Mon Dec 17 22:20:40 2012 +0100 quartz: make setting_same_owner member of GtkClipboardOwner @public to fix the build, thanks to parafin for the patch. (cherry picked from commit e3e055f8551ac8ee033f361261c849c612554184) gtk/gtkclipboard-quartz.c | 1 + 1 file changed, 1 insertion(+)