Bug 635401 - Segfault when checking name of graphics driver vendor - r=bas, a=joe

This commit is contained in:
Benoit Jacob 2011-02-24 17:17:34 -05:00
parent d6905754de
commit 8cffd874ec

View File

@ -183,12 +183,16 @@ GLXLibrary::EnsureInitialized()
vendor = xQueryServerString(display, screen, GLX_VENDOR);
serverVersionStr = xQueryServerString(display, screen, GLX_VERSION);
if (strcmp(vendor, "NVIDIA Corporation") &&
PRBool IsDriverBlacklisted = !vendor || // it's been reported that a VNC X server was returning vendor=null
!serverVersionStr ||
strcmp(vendor, "NVIDIA Corporation");
if (IsDriverBlacklisted &&
!PR_GetEnv("MOZ_GLX_IGNORE_BLACKLIST"))
{
printf("[GLX] your GL driver is currently blocked. If you would like to bypass this, "
"define the MOZ_GLX_IGNORE_BLACKLIST environment variable.\n");
return nsnull;
return PR_FALSE;
}
if (!GLXVersionCheck(1, 1))