glx: Add comments around some extension string weirdness

This commit is contained in:
Ian Romanick 2009-02-16 12:08:28 -08:00
parent caa5310e16
commit 51ae4d6bbf
2 changed files with 9 additions and 1 deletions

View File

@ -1136,6 +1136,10 @@ __glXDRIscreenProbe(ScreenPtr pScreen)
__glXScreenInit(&screen->base, pScreen);
/* The first call simply determines the length of the extension string.
* This allows us to allocate some memory to hold the extension string,
* but it requires that we call __glXGetExtensionString a second time.
*/
buffer_size = __glXGetExtensionString(screen->glx_enable_bits, NULL);
if (buffer_size > 0) {
if (screen->base.GLXextensions != NULL) {

View File

@ -583,6 +583,10 @@ __glXDRIscreenProbe(ScreenPtr pScreen)
__glXScreenInit(&screen->base, pScreen);
/* The first call simply determines the length of the extension string.
* This allows us to allocate some memory to hold the extension string,
* but it requires that we call __glXGetExtensionString a second time.
*/
buffer_size = __glXGetExtensionString(screen->glx_enable_bits, NULL);
if (buffer_size > 0) {
if (screen->base.GLXextensions != NULL) {