aboutsummaryrefslogtreecommitdiff
path: root/nx-X11/programs/Xserver/hw/nxagent/Colormap.c
diff options
context:
space:
mode:
Diffstat (limited to 'nx-X11/programs/Xserver/hw/nxagent/Colormap.c')
-rw-r--r--nx-X11/programs/Xserver/hw/nxagent/Colormap.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/nx-X11/programs/Xserver/hw/nxagent/Colormap.c b/nx-X11/programs/Xserver/hw/nxagent/Colormap.c
index 9308390fe..c173f322c 100644
--- a/nx-X11/programs/Xserver/hw/nxagent/Colormap.c
+++ b/nx-X11/programs/Xserver/hw/nxagent/Colormap.c
@@ -482,7 +482,7 @@ void nxagentResolveColor(unsigned short *pRed, unsigned short *pGreen,
unsigned int limg = pVisual->ColormapEntries - 1;
/* rescale to gray then [0..limg] then [0..65535] then rgb bits */
*pRed = (30L * *pRed + 59L * *pGreen + 11L * *pBlue) / 100;
- *pRed = ((((*pRed * (limg + 1))) >> 16) * 65535) / limg;
+ *pRed = (((*pRed * (limg + 1)) >> 16) * 65535) / limg;
*pBlue = *pGreen = *pRed = ((*pRed >> shift) * 65535) / lim;
}
else
@@ -573,7 +573,7 @@ Bool nxagentReconnectAllColormap(void *p0)
for (int cid = 0; (cid < MAXCLIENTS) && success; cid++)
{
- if (clients[cid] && success)
+ if (clients[cid])
{
FindClientResourcesByType(clients[cid], RT_COLORMAP, nxagentReconnectColormap, &success);
}