Bug in interaction between freeglut and mesa-7.3-rc2

Ian Romanick idr at freedesktop.org
Fri Jan 16 17:00:06 PST 2009


On Fri, 2009-01-16 at 12:14 +0100, Florian Echtler wrote:

> I've found a bug in the interaction between freeglut and mesa. This
> applies to mesa 7.2 and 7.3-rc2 and occurs both with freeglut-current
> and freeglut-2.6.0-rc1. I'm using the radeon driver on a Radeon Mobility
> X1400.
> 
> The bug causes a segfault in libGL.so, though even with debug info
> enabled, I can't see the exact location. However, I can work around the
> bug when, in freeglut, I replace 

Why would you do that?  There is no improvement to freeglut and no
benefit to its users.  If the read drawable and the drawing drawable are
always the same, just use glXMakeCurrent.  You already have a tool that
does *exactly* the job you need done.  Why change to a tool that is
intended to suit a different need?

>     glXMakeContextCurrent(
>         fgDisplay.Display,
>         window->Window.Handle,
>         window->Window.Handle,
>         window->Window.Context
>     );
> 
> with 
> 
>     glXMakeCurrent(
>         fgDisplay.Display,
>         window->Window.Handle,
>         window->Window.Context
>     );
> 
> According to the GLX spec, these two calls should be equivalent.

They are "morally equivalent."  However, glXMakeContextCurrent requires
that the drawables be created by by one of glXCreateWindow,
glXCreatePixmap, or glXCreatePbuffer.

See:

http://www.opengl.org/sdk/docs/man/xhtml/glXMakeContextCurrent.xml
http://www.opengl.org/sdk/docs/man/xhtml/glXMakeCurrent.xml

See also this thread on the Mesa list:

http://marc.info/?l=mesa3d-dev&m=123211968809340&w=2

> However, the first one causes a segfault, the second one doesn't. So I
> suppose this is really a bug in mesa somewhere. Is this information
> sufficient to fix it, or do you need anything else?

See:

http://bugs.freedesktop.org/show_bug.cgi?id=19625

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 197 bytes
Desc: This is a digitally signed message part
URL: <http://lists.x.org/archives/xorg/attachments/20090116/eab120b7/attachment.pgp>


More information about the xorg mailing list