summaryrefslogtreecommitdiff
path: root/src/mesa/drivers
diff options
context:
space:
mode:
authorBrian Paul <brianp@vmware.com>2009-10-02 07:51:15 -0600
committerBrian Paul <brianp@vmware.com>2009-10-02 07:51:19 -0600
commit584b0879ac2ec2420ea6866e47eb90e1a980e758 (patch)
tree5fa17a73bdbebae305d480922cc47f7c18b46e57 /src/mesa/drivers
parentabc12d0636a5f7fb938c0305cb1b642d5ec0afce (diff)
xlib: use bitwise-and to test GLX_RGBA_BIT in choose_visual()
The parameter is a bitmask.
Diffstat (limited to 'src/mesa/drivers')
-rw-r--r--src/mesa/drivers/x11/fakeglx.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/mesa/drivers/x11/fakeglx.c b/src/mesa/drivers/x11/fakeglx.c
index eb7c4f6417..6449dc88b0 100644
--- a/src/mesa/drivers/x11/fakeglx.c
+++ b/src/mesa/drivers/x11/fakeglx.c
@@ -1197,10 +1197,10 @@ choose_visual( Display *dpy, int screen, const int *list, GLboolean fbConfig )
if (!fbConfig)
return NULL;
parselist++;
- if (*parselist == GLX_RGBA_BIT) {
+ if (*parselist & GLX_RGBA_BIT) {
rgb_flag = GL_TRUE;
}
- else if (*parselist == GLX_COLOR_INDEX_BIT) {
+ else if (*parselist & GLX_COLOR_INDEX_BIT) {
rgb_flag = GL_FALSE;
}
else if (*parselist == 0) {