Bug 659842 comment 86 - accidentally removed a glXDestroyContext call + fix a warning in opt build - r=trivial-fix

This commit is contained in:
Benoit Jacob 2011-06-17 21:42:31 -04:00
parent 30d1e7f053
commit 1727f110cb
2 changed files with 5 additions and 1 deletions

View File

@ -404,7 +404,10 @@ TRY_AGAIN_NO_SHARING:
MarkDestroyed();
// see bug 659842 comment 76
bool success = sGLXLibrary.xMakeCurrent(mDisplay, None, nsnull);
#ifdef DEBUG
bool success =
#endif
sGLXLibrary.xMakeCurrent(mDisplay, None, nsnull);
NS_ABORT_IF_FALSE(success,
"glXMakeCurrent failed to release GL context before we call glXDestroyContext!");

View File

@ -214,6 +214,7 @@ static void glxtest()
///// so we might be staying alive for longer than expected, so it's important to consume as little memory as
///// possible. Also we want to check that we're able to do that too without generating X errors.
glXMakeCurrent(dpy, None, NULL); // must release the GL context before destroying it
glXDestroyContext(dpy, context);
glXDestroyPixmap(dpy, glxpixmap);
XFreePixmap(dpy, pixmap);
XCloseDisplay(dpy);