Code

Fix compile when lcms is disabled (someone please check that this fix is correct).
[inkscape.git] / src / svg / svg-color.cpp
index 46779311e74ec741452acfadff9382521eb228ad..7d43b68eef18d75c2e82c6f7d4e967ceb1f2ee95 100644 (file)
@@ -351,9 +351,9 @@ sp_svg_read_color(gchar const *str, gchar const **end_ptr, guint32 dfl)
      * this check wrapper. */
     gchar const *end = str;
     guint32 const ret = internal_sp_svg_read_color(str, &end, dfl);
-    assert(ret == dfl && end == str
+    assert(((ret == dfl) && (end == str))
            || (((ret & 0xff) == 0)
-               && str < end));
+               && (str < end)));
     if (str < end) {
         gchar *buf = (gchar *) g_malloc(end + 1 - str);
         memcpy(buf, str, end - str);
@@ -464,6 +464,7 @@ sp_svg_create_color_hash()
     return colors;
 }
 
+#if ENABLE_LCMS
 //helper function borrowed from src/widgets/sp-color-icc-selector.cpp:
 void getThings( DWORD space, gchar const**& namers, gchar const**& tippies, guint const*& scalies );
 
@@ -497,6 +498,7 @@ g_message("transform to sRGB done");
         }
     }
 }
+#endif //ENABLE_LCMS
 
 /*
  * Some discussion at http://markmail.org/message/bhfvdfptt25kgtmj