Bug 56922

Summary: glXUseXFont throws a BadDrawable
Product: Mesa Reporter: djee <djeedai>
Component: GLXAssignee: mesa-dev
Status: RESOLVED MOVED QA Contact:
Severity: major    
Priority: medium    
Version: 8.0   
Hardware: x86-64 (AMD64)   
OS: Linux (All)   
Whiteboard:
i915 platform: i915 features:

Description djee 2012-11-09 14:27:22 UTC
Hi,

I recently switched back to Mesa/Gallium from proprietary driver (needed GL 3.3) after the drop of ATI r600 support, and the exact same program (I developed myself) now crash with Mesa, but it do not crash neither with the proprietary driver nor on another nvidia-based machine.
Basically I get a BadDrawable on glXUseXFont(), whatever the font I try to use. I never had a problem before with this.

Here is a GDB backtrace:

#0  0x00007ffff66fd475 in *__GI_raise (sig=<optimized out>) at ../nptl/sysdeps/unix/sysv/linux/raise.c:64
#1  0x00007ffff67006f0 in *__GI_abort () at abort.c:92
#2  0x00007ffff66f6621 in *__GI___assert_fail (assertion=0x46bff5 "0", file=<optimized out>, line=438, function=0x46c820 "int xerrhandler_debug(Display*, XErrorEvent*)") at assert.c:81
#3  0x000000000043d705 in xerrhandler_debug (dpy=<error reading variable: Could not find the frame base for "xerrhandler_debug(Display*, XErrorEvent*)".>, 
    error=<error reading variable: Could not find the frame base for "xerrhandler_debug(Display*, XErrorEvent*)".>) at [...]
#4  0x00007ffff63d6563 in _XError (dpy=0x758c60, rep=<optimized out>) at ../../src/XlibInt.c:1583
#5  0x00007ffff63d35d1 in handle_error (dpy=0x758c60, err=0x92e0c0, in_XReply=<optimized out>) at ../../src/xcb_io.c:212
#6  0x00007ffff63d3615 in handle_response (dpy=0x758c60, response=0x92e0c0, in_XReply=<optimized out>) at ../../src/xcb_io.c:324
#7  0x00007ffff63d4420 in _XReply (dpy=0x758c60, rep=0x7fffffffd900, extra=0, discard=1) at ../../src/xcb_io.c:626
#8  0x00007ffff63ca038 in XQueryExtension (dpy=0x758c60, name=0x7ffff1987ca0 "RENDER", major_opcode=0x7fffffffd964, first_event=0x7fffffffd968, first_error=0x7fffffffd96c) at ../../src/QuExt.c:48
#9  0x00007ffff63be055 in XInitExtension (dpy=0x758c60, name=0x7ffff1987ca0 "RENDER") at ../../src/InitExt.c:47
#10 0x00007ffff1785afc in XRenderFindDisplay () from /usr/lib/x86_64-linux-gnu/libXrender.so.1
#11 0x00007ffff1785e39 in XRenderQueryExtension () from /usr/lib/x86_64-linux-gnu/libXrender.so.1
#12 0x00007ffff198c546 in _XcursorGetDisplayInfo () from /usr/lib/x86_64-linux-gnu/libXcursor.so.1
#13 0x00007ffff198c9d9 in XcursorSupportsARGB () from /usr/lib/x86_64-linux-gnu/libXcursor.so.1
#14 0x00007ffff198f263 in XcursorNoticeCreateBitmap () from /usr/lib/x86_64-linux-gnu/libXcursor.so.1
#15 0x00007ffff63b2f80 in XCreatePixmap (dpy=0x758c60, d=<optimized out>, width=10, height=10, depth=1) at ../../src/CrPixmap.c:61
#16 0x00007ffff7bbcdd1 in ?? () from /usr/lib/x86_64-linux-gnu/libGL.so.1
#17 0x0000000000446f5d in [my program]

This *seems* related to this bug: http://blog.gmane.org/gmane.network.vnc.tigervnc.user/month=20111201
However I tried changing the font I request in XLoadQueryFont() without success.

Please note that I use both XCreateWindow() then glXCreateWindow(). I compiled an example (progs/xdemos/xfont.c in mesa 7.7.1), and it runs perfectly well, but it does *not* use glXCreateWindow(). Did I miss something there? I thought that both methods were similar, mine being more rigorous and the one in xfont.c using some legacy support.

Thanks in advance for any help :)
Comment 1 GitLab Migration User 2019-09-18 17:44:31 UTC
-- GitLab Migration Automatic Message --

This bug has been migrated to freedesktop.org's GitLab instance and has been closed from further activity.

You can subscribe and participate further through the new bug through this link to our GitLab instance: https://gitlab.freedesktop.org/mesa/mesa/issues/89.

Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.