+2002-03-08 Juanma Barranquero <lektu@terra.es>
+
+ * w32fns.c (Fx_display_color_cells): Force 24+ bit color depths to
+ 24-bit.
+
2002-03-06 Jason Rumney <jasonr@gnu.org>
* w32term.c (x_draw_hollow_cursor): Draw same size as block cursor.
else
cap = GetDeviceCaps (hdc,NUMCOLORS);
+ /* We force 24+ bit depths to 24-bit, both to prevent an overflow
+ and because probably is more meaningful on Windows anyway */
if (cap < 0)
- cap = 1 << (dpyinfo->n_planes * dpyinfo->n_cbits);
+ cap = 1 << min(dpyinfo->n_planes * dpyinfo->n_cbits, 24);
ReleaseDC (dpyinfo->root_window, hdc);