summaryrefslogtreecommitdiff
path: root/src/xftcolor.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/xftcolor.c')
-rw-r--r--src/xftcolor.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/xftcolor.c b/src/xftcolor.c
index a323822..739dc2d 100644
--- a/src/xftcolor.c
+++ b/src/xftcolor.c
@@ -90,9 +90,9 @@ XftColorAllocValue (Display *dpy,
green_len = masklen (visual->green_mask);
blue_shift = maskbase (visual->blue_mask);
blue_len = masklen (visual->blue_mask);
- result->pixel = (((color->red >> (16 - red_len)) << red_shift) |
- ((color->green >> (16 - green_len)) << green_shift) |
- ((color->blue >> (16 - blue_len)) << blue_shift));
+ result->pixel = (unsigned long)(((color->red >> (16 - red_len)) << red_shift) |
+ ((color->green >> (16 - green_len)) << green_shift) |
+ ((color->blue >> (16 - blue_len)) << blue_shift));
}
else
{