From 15b30fde179cba3877182cd51b0f870ef29ffaee Mon Sep 17 00:00:00 2001 From: Adam Jackson Date: Thu, 22 Oct 2009 17:29:01 -0400 Subject: [PATCH] dix: Fix up colormap fixup. FindClientResourcesByType() will walk all colormaps on all screens; we only want to fix up the current screen. Otherwise, screens > 0 will have the visual pointers for their colormaps pointing off into space. Signed-off-by: Adam Jackson --- dix/colormap.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/dix/colormap.c b/dix/colormap.c index d702b0204..bf9794125 100644 --- a/dix/colormap.c +++ b/dix/colormap.c @@ -2705,6 +2705,9 @@ static void _colormap_find_resource(pointer value, XID id, ColormapPtr cmap = value; int j; + if (pScreen != cmap->pScreen) + return; + j = cmap->pVisual - pScreen->visuals; cmap->pVisual = &visuals[j]; }