-
Notifications
You must be signed in to change notification settings - Fork 161
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Getting a crash from epoxy_get_proc_address #36
Comments
Any idea why I could be getting this crash? The library seems to have the glGetStringi symbol |
I note that the gdb indicates that you've got both mesa libEGL and nvidia binary drivers loaded at the same time, and this will surely go badly. Has GTK mixed up their initialization, or made multiple contexts from different drivers? |
The only way this could be our fault is if GTK is doing things with only for of GLX and EGL, and epoxy is erroneously loading the other. You'd want to break on the dlopen() inside of get_dlopen_handle() to see when the loads of the two libraries are happening. |
So things seem to have improved over time. Now it does not seg fault but I get this error: |
Checking at the code I see that you try to see if it should use GLX or EGL depending on the GetCurrentContext method. But for what I can see it is not calling MakeCurrentContext before that call. And from the docs it should return NULL as it is the case. Maybe I am missing something? |
After fixing the driver I am on a similar state as I was at the beginning #0 0x0000000000000000 in ?? () |
and the initial libraries: |
So I've found the reason of the crash. While it is in our side it is still strange what epoxy is doing. It is using glXGetProcAddress to look for glXGetProcAddress. |
Have you not made a context current before calling GL functions? |
So there were a couple of problems on our driver. First that we did not support a extension so gdk was failing to create the context, so the error in epoxy was actually correct. The second is that we were getting the backtrace because for some reason epoxy tries to get glXGetProcAddress by using glXGetProcAddress to get the address to that method and we were not handling that case properly. I think though that this is a bug in epoxy since it is really weird that you do that. |
The backtrace wasn't showing what you're saying about glXGPA using glXGPA. Note that glXGPA is different from glXGPAARB. glXGPAARB is libGL ABI, while glXGPA is 1.4, and thus must be looked up using glXGPA. |
Yeah, the stack trace was kind of hiding the real problem. Thanks for the comments, I guess we can close this now. |
Program received signal SIGSEGV, Segmentation fault.
0x0000000000000000 in ?? ()
Missing separate debuginfos, use: debuginfo-install dbus-libs-1.6.12-9.fc20.x86_64 expat-2.1.0-7.fc20.x86_64 freetype-2.5.0-5.fc20.x86_64 glibc-2.18-16.fc20.x86_64 gmp-5.1.2-2.fc20.x86_64 gnutls-3.1.27-1.fc20.x86_64 keyutils-libs-1.5.9-1.fc20.x86_64 krb5-libs-1.11.5-11.fc20.x86_64 libICE-1.0.8-6.fc20.x86_64 libSM-1.2.1-6.fc20.x86_64 libX11-1.6.1-1.fc20.x86_64 libXau-1.0.8-2.fc20.x86_64 libXcomposite-0.4.4-4.fc20.x86_64 libXcursor-1.1.14-2.fc20.x86_64 libXdamage-1.1.4-4.fc20.x86_64 libXdmcp-1.1.1-5.fc20.x86_64 libXext-1.3.2-2.fc20.x86_64 libXfixes-5.0.1-2.fc20.x86_64 libXi-1.7.4-1.fc20.x86_64 libXinerama-1.1.3-2.fc20.x86_64 libXrandr-1.4.1-2.fc20.x86_64 libXrender-0.9.8-2.fc20.x86_64 libcom_err-1.42.8-3.fc20.x86_64 libdrm-2.4.54-1.fc20.x86_64 libffi-3.0.13-5.fc20.x86_64 libgcc-4.8.3-7.fc20.x86_64 libmodman-2.0.1-7.fc20.x86_64 libpng-1.6.6-3.fc20.x86_64 libproxy-0.4.11-8.fc20.x86_64 libselinux-2.2.1-6.fc20.x86_64 libstdc++-4.8.3-7.fc20.x86_64 libtasn1-3.8-2.fc20.x86_64 libuuid-2.24.2-1.fc20.x86_64 mesa-libEGL-10.1.5-1.20140607.fc20.x86_64 mesa-libgbm-10.1.5-1.20140607.fc20.x86_64 mesa-libglapi-10.1.5-1.20140607.fc20.x86_64 mesa-libwayland-egl-10.1.5-1.20140607.fc20.x86_64 nettle-2.7.1-3.fc20.x86_64 nice-dcv-server-2013.0-9935.x86_64 openssl-libs-1.0.1e-40.fc20.x86_64 pcre-8.33-6.fc20.x86_64 pixman-0.30.0-5.fc20.x86_64 systemd-libs-208-22.fc20.x86_64 trousers-0.3.13-1.fc20.x86_64 xorg-x11-drv-nvidia-libs-331.89-2.fc20.x86_64 xz-libs-5.1.2-12alpha.fc20.x86_64 zlib-1.2.8-3.fc20.x86_64
(gdb) bt
#0 0x0000000000000000 in ?? ()
#1 0x00007ffff34597f3 in epoxy_glXGetProcAddressARB_global_rewrite_ptr (
#2 0x00007ffff3411424 in epoxy_get_proc_address (
#3 0x00007ffff341125e in epoxy_get_core_proc_address (
#4 0x00007ffff34118b2 in gl_provider_resolver (
#5 0x00007ffff341cf46 in epoxy_glGetStringi_resolver ()
#6 0x00007ffff34382f3 in epoxy_glGetStringi_global_rewrite_ptr (name=7939,
#7 0x00007ffff3410f42 in epoxy_internal_has_gl_extension (
#8 0x00007ffff3411095 in epoxy_has_gl_extension (
---Type to continue, or q to quit---
at dispatch_common.c:417
#9 0x00007ffff711e20d in gdk_gl_context_realize (context=0x8ac540)
#10 0x00007ffff711e352 in gdk_gl_context_make_current (context=0x8ac540)
#11 0x00007ffff76120d7 in gtk_gl_area_realize (widget=0x742320)
#12 0x0000000000405818 in gtk_gears_realize (widget=0x742320) at gtkgears.c:312
#13 0x00007ffff2d071ab in g_cclosure_marshal_VOID__VOIDv (closure=0x666e80,
#14 0x00007ffff2d04838 in g_type_class_meta_marshalv (closure=0x666e80,
#15 0x00007ffff2d043fb in _g_closure_invoke_va (closure=0x666e80,
#16 0x00007ffff2d1f4b3 in g_signal_emit_valist (instance=0x742320,
#17 0x00007ffff2d20664 in g_signal_emit (instance=0x742320, signal_id=8,
#18 0x00007ffff782c5af in gtk_widget_realize (widget=0x742320)
---Type to continue, or q to quit---
at gtkwidget.c:5520
#19 0x00007ffff782b692 in gtk_widget_map (widget=0x742320) at gtkwidget.c:5049
#20 0x00007ffff75766fc in gtk_container_map_child (child=0x742320,
#21 0x00007ffff751344e in gtk_box_forall (container=0x6a5660,
#22 0x00007ffff7573f01 in gtk_container_forall (container=0x6a5660,
#23 0x00007ffff7576746 in gtk_container_map (widget=0x6a5660)
#24 0x00007ffff2d071ab in g_cclosure_marshal_VOID__VOIDv (closure=0x663e50,
#25 0x00007ffff2d04838 in g_type_class_meta_marshalv (closure=0x663e50,
#26 0x00007ffff2d043fb in _g_closure_invoke_va (closure=0x663e50,
#27 0x00007ffff2d1f4b3 in g_signal_emit_valist (instance=0x6a5660,
---Type to continue, or q to quit---
signal_id=6, detail=0, var_args=0x7fffffffbf58) at gsignal.c:3195
#28 0x00007ffff2d20664 in g_signal_emit (instance=0x6a5660, signal_id=6,
#29 0x00007ffff782b6b0 in gtk_widget_map (widget=0x6a5660) at gtkwidget.c:5051
#30 0x00007ffff75766fc in gtk_container_map_child (child=0x6a5660,
#31 0x00007ffff751344e in gtk_box_forall (container=0x6a5510,
#32 0x00007ffff7573f01 in gtk_container_forall (container=0x6a5510,
#33 0x00007ffff7576746 in gtk_container_map (widget=0x6a5510)
#34 0x00007ffff2d071ab in g_cclosure_marshal_VOID__VOIDv (closure=0x663e50,
#35 0x00007ffff2d04838 in g_type_class_meta_marshalv (closure=0x663e50,
#36 0x00007ffff2d043fb in _g_closure_invoke_va (closure=0x663e50,
---Type to continue, or q to quit---
param_types=0x0) at gclosure.c:831
#37 0x00007ffff2d1f4b3 in g_signal_emit_valist (instance=0x6a5510,
#38 0x00007ffff2d20664 in g_signal_emit (instance=0x6a5510, signal_id=6,
#39 0x00007ffff782b6b0 in gtk_widget_map (widget=0x6a5510) at gtkwidget.c:5051
#40 0x00007ffff75766fc in gtk_container_map_child (child=0x6a5510,
#41 0x00007ffff76c3f15 in gtk_overlay_forall (overlay=0x7421a0,
#42 0x00007ffff7573f01 in gtk_container_forall (container=0x7421a0,
#43 0x00007ffff7576746 in gtk_container_map (widget=0x7421a0)
#44 0x00007ffff76c3c48 in gtk_overlay_map (widget=0x7421a0) at gtkoverlay.c:448
#45 0x00007ffff2d071ab in g_cclosure_marshal_VOID__VOIDv (closure=0x663e50,
#46 0x00007ffff2d04838 in g_type_class_meta_marshalv (closure=0x663e50,
---Type to continue, or q to quit---
marshal_data=0xb8, n_params=0, param_types=0x0) at gclosure.c:988
#47 0x00007ffff2d043fb in _g_closure_invoke_va (closure=0x663e50,
#48 0x00007ffff2d1f4b3 in g_signal_emit_valist (instance=0x7421a0,
#49 0x00007ffff2d20664 in g_signal_emit (instance=0x7421a0, signal_id=6,
#50 0x00007ffff782b6b0 in gtk_widget_map (widget=0x7421a0) at gtkwidget.c:5051
#51 0x00007ffff7851651 in gtk_window_map (widget=0x6ae240) at gtkwindow.c:5918
#52 0x00007ffff2d071ab in g_cclosure_marshal_VOID__VOIDv (closure=0x663e50,
#53 0x00007ffff2d04838 in g_type_class_meta_marshalv (closure=0x663e50,
#54 0x00007ffff2d043fb in _g_closure_invoke_va (closure=0x663e50,
#55 0x00007ffff2d1f4b3 in g_signal_emit_valist (instance=0x6ae240,
#56 0x00007ffff2d20664 in g_signal_emit (instance=0x6ae240, signal_id=6,
---Type to continue, or q to quit---
detail=0) at gsignal.c:3342
#57 0x00007ffff782b6b0 in gtk_widget_map (widget=0x6ae240) at gtkwidget.c:5051
#58 0x00007ffff785126e in gtk_window_show (widget=0x6ae240) at gtkwindow.c:5823
#59 0x00007ffff2d07119 in g_cclosure_marshal_VOID__VOID (closure=0x662210,
#60 0x00007ffff2d047b3 in g_type_class_meta_marshal (closure=0x662210,
#61 0x00007ffff2d04163 in g_closure_invoke (closure=0x662210,
#62 0x00007ffff2d20af3 in signal_emit_unlocked_R (node=0x663ca0, detail=0,
#63 0x00007ffff2d20111 in g_signal_emit_valist (instance=0x6ae240,
#64 0x00007ffff2d20664 in g_signal_emit (instance=0x6ae240, signal_id=4,
#65 0x00007ffff782afbf in gtk_widget_show (widget=0x6ae240) at gtkwidget.c:4859
#66 0x0000000000403acd in main (argc=1, argv=0x7fffffffdb88) at gdkgears.c:233
The text was updated successfully, but these errors were encountered: