summaryrefslogtreecommitdiff
path: root/x11/xmx/patches/patch-bj
blob: 5347fb9e1996d781bad704bb5e037d7243a4317c (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
$NetBSD: patch-bj,v 1.1 2008/08/31 06:52:29 dholland Exp $

--- server/color.c.orig	1998-05-05 15:01:35.000000000 -0400
+++ server/color.c	2008-08-31 01:25:45.000000000 -0400
@@ -31,6 +31,7 @@
 #include <sys/select.h>
 #endif
 #include <stdlib.h>
+#include <string.h>
 #define NEED_REPLIES
 #define NEED_EVENTS
 #include <X11/Xproto.h>
@@ -807,7 +808,7 @@ alloc_cells_reply
          npixels = ((xAllocColorCellsReply *)rp)->nPixels;
          nmasks = ((xAllocColorCellsReply *)rp)->nMasks;
          real_pixels = (pixel_t *)((xAllocColorCellsReply *)rp + 1);
-         maskp = (mask_t *)(real_pixels[npixels]);
+         maskp = (mask_t *)&(real_pixels[npixels]);
          real_mask = 0;
          for (i=0; i<nmasks; i++)
             real_mask |= maskp[i];