]> git.saurik.com Git - wxWidgets.git/commitdiff
Warning fix.
authorWłodzimierz Skiba <abx@abx.art.pl>
Mon, 29 May 2006 10:11:45 +0000 (10:11 +0000)
committerWłodzimierz Skiba <abx@abx.art.pl>
Mon, 29 May 2006 10:11:45 +0000 (10:11 +0000)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@39432 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775

src/common/imagjpeg.cpp

index c10f764da40d3b53794d166fb056d392876d0454..14b2d188350e551d7726b38ed74b63ea30320d1c 100644 (file)
@@ -209,13 +209,13 @@ static inline void wx_cmyk_to_rgb(unsigned char* rgb, const unsigned char* cmyk)
     register int c;
 
     c = k + k2 * (255 - cmyk[0]) / 255;
-    rgb[0] = (c > 255) ? 0 : (255 - c);
+    rgb[0] = (unsigned char)((c > 255) ? 0 : (255 - c));
 
     c = k + k2 * (255 - cmyk[1]) / 255;
-    rgb[1] = (c > 255) ? 0 : (255 - c);
+    rgb[1] = (unsigned char)((c > 255) ? 0 : (255 - c));
 
     c = k + k2 * (255 - cmyk[2]) / 255;
-    rgb[2] = (c > 255) ? 0 : (255 - c);
+    rgb[2] = (unsigned char)((c > 255) ? 0 : (255 - c));
 }
 
 // temporarily disable the warning C4611 (interaction between '_setjmp' and