Fix __glXInitializeVisualConfigFromTags's handling of unrecognized fbconfig tags.
authorAaron Plattner <aplattner@nvidia.com>
Thu, 22 Apr 2010 16:30:42 +0000 (09:30 -0700)
committerIan Romanick <ian.d.romanick@intel.com>
Fri, 23 Apr 2010 18:48:11 +0000 (11:48 -0700)
__glXInitializeVisualConfigFromTags doesn't skip the payload of
unrecognized tags.  Instead, it treats the value as if it were the
next tag, which can happen if the server's GLX extension is not
Mesa's.  For example, this falls down when NVIDIA sends a
GLX_FLOAT_COMPONENTS_NV = 0 pair, causing
__glXInitializeVisualConfigFromTags to bail out early.

Signed-off-by: Aaron Plattner <aplattner@nvidia.com>
Signed-off-by: Ian Romanick <ian.d.romanick@intel.com>
src/glx/glxext.c

index 5289354a521233673a20d12688770d5a9807b4cb..6d6f89e79a274c66eaad034c4a1479d74f374cec 100644 (file)
@@ -539,6 +539,8 @@ __glXInitializeVisualConfigFromTags(__GLcontextModes * config, int count,
          i = count;
          break;
       default:
+         /* Ignore the unrecognized tag's value */
+         bp++;
          break;
       }
    }