Gtk+4 (3.89.4) with Quartz backend: all apps segfault
Submitted by Tom Schoonjans
Assigned to gtk-quartz maintainers
Link to original bug (#779184)
Description
Hi,
I tried to see how the current unstable gtk+4 release works when compiled on Mac OS X with quartz backend. Though everything compiles fine, all executables I tried segfault immediately. This is the backtrace of gtk4-icon-browser for example:
(lldb) run
Process 78483 launched: '/Users/awf63395/software/bin/gtk4-icon-browser' (x86_64)
2017-02-24 15:49:47.888746 gtk4-icon-browser[78483:21750657] *** WARNING: Method userSpaceScaleFactor in class NSView is deprecated on 10.7 and later. It should not be used in new applications. Use convertRectToBacking: instead.
Process 78483 stopped
* thread #1: tid = 0x14be381, 0x0000000000000000, queue = 'com.apple.main-thread', stop reason = EXC_BAD_ACCESS (code=1, address=0x0)
frame #0: 0x0000000000000000
error: memory read failed for 0x0
(lldb) bt
* thread #1: tid = 0x14be381, 0x0000000000000000, queue = 'com.apple.main-thread', stop reason = EXC_BAD_ACCESS (code=1, address=0x0)
* frame #0: 0x0000000000000000
frame #1: 0x00000001005c2e82 libgtk-4.0.dylib`gdk_display_get_monitor(display=0x0000000102802120, monitor_num=0) + 210 at gdkdisplay.c:2338
frame #2: 0x00000001005147f1 libgtk-4.0.dylib`gtk_widget_get_scale_factor(widget=0x000000010284a2e0) + 305 at gtkwidget.c:9425
frame #3: 0x000000010053452c libgtk-4.0.dylib`gtk_window_init(window=0x000000010284a2e0) + 940 at gtkwindow.c:1711
frame #4: 0x0000000100fc658c libgobject-2.0.0.dylib`g_type_create_instance + 621
frame #5: 0x0000000100fb58e4 libgobject-2.0.0.dylib`g_object_new_internal + 52
frame #6: 0x0000000100fb57c4 libgobject-2.0.0.dylib`g_object_new_valist + 1010
frame #7: 0x0000000100fb513b libgobject-2.0.0.dylib`g_object_new + 187
frame #8: 0x00000001000015a8 gtk4-icon-browser`icon_browser_window_new(app=0x00000001028041a0) + 40 at iconbrowserwin.c:874
frame #9: 0x00000001000011dd gtk4-icon-browser`icon_browser_app_activate(app=0x00000001028041a0) + 45 at iconbrowserapp.c:56
frame #10: 0x0000000100faf87d libgobject-2.0.0.dylib`g_closure_invoke + 260
frame #11: 0x0000000100fc3d60 libgobject-2.0.0.dylib`signal_emit_unlocked_R + 2127
frame #12: 0x0000000100fc489d libgobject-2.0.0.dylib`g_signal_emit_valist + 1889
frame #13: 0x0000000100fc4f0a libgobject-2.0.0.dylib`g_signal_emit + 142
frame #14: 0x0000000100e9c2ef libgio-2.0.0.dylib`g_application_real_local_command_line + 1136
frame #15: 0x0000000100131f35 libgtk-4.0.dylib`gtk_application_local_command_line(application=0x00000001028041a0, arguments=0x00007fff5fbff990, exit_status=0x00007fff5fbff98c) + 69 at gtkapplication.c:330
frame #16: 0x0000000100e9af2e libgio-2.0.0.dylib`g_application_run + 305
frame #17: 0x0000000100000eef gtk4-icon-browser`main(argc=1, argv=0x00007fff5fbffa10) + 63 at main.c:7
frame #18: 0x00007fffdb2b0255 libdyld.dylib`start + 1
All other programs I tried crash at the same line in gdkdisplay.c...
This was done on a Retina 5K iMac running macOS Sierra.
Let me know if more information is required..
Thanks,
Tom
Version: 3.89.x