Revision: 48414
          http://brlcad.svn.sourceforge.net/brlcad/?rev=48414&view=rev
Author:   starseeker
Date:     2012-01-11 17:53:23 +0000 (Wed, 11 Jan 2012)
Log Message:
-----------
is_linear means we don't have a cmp - in that case, don't try to use it. CID 271

Modified Paths:
--------------
    brlcad/trunk/src/libfb/if_X.c

Modified: brlcad/trunk/src/libfb/if_X.c
===================================================================
--- brlcad/trunk/src/libfb/if_X.c       2012-01-11 17:48:13 UTC (rev 48413)
+++ brlcad/trunk/src/libfb/if_X.c       2012-01-11 17:53:23 UTC (rev 48414)
@@ -1177,8 +1177,9 @@
     if (XI(ifp)->depth != 8)
        return 0;       /* no X colormap allocated - XXX */
 
-    /* If MODE_2_8BIT, load it in the real window colormap */
-    if ((XI(ifp)->mode&MODE_2MASK) == MODE_2_8BIT) {
+    /* If MODE_2_8BIT, load it in the real window colormap.  If
+     * is_linear is true, cmp will not be populated - do nothing. */
+    if ((XI(ifp)->mode&MODE_2MASK) == MODE_2_8BIT && !is_linear) {
        for (i = 0; i < 256; i++) {
            /* Both sides expect 16-bit left-justified maps */
            color_defs[i].pixel = i;

This was sent by the SourceForge.net collaborative development platform, the 
world's largest Open Source development site.


------------------------------------------------------------------------------
Ridiculously easy VDI. With Citrix VDI-in-a-Box, you don't need a complex
infrastructure or vast IT resources to deliver seamless, secure access to
virtual desktops. With this all-in-one solution, easily deploy virtual 
desktops for less than the cost of PCs and save 60% on VDI infrastructure 
costs. Try it free! http://p.sf.net/sfu/Citrix-VDIinabox
_______________________________________________
BRL-CAD Source Commits mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/brlcad-commits

Reply via email to