Commit 42ed35c6 authored by Paul Eggert's avatar Paul Eggert

Pacify -Wdouble-promotion in ImageMagick code

* src/image.c (imagemagick_load_image): Use double division, and
eliminate a cast.  This avoids a -Wdouble-promotion warning with
GCC 7.3 on Ubuntu 18.04.
parent d8bef4b5
......@@ -8824,7 +8824,8 @@ imagemagick_load_image (struct frame *f, struct image *img,
#endif /* HAVE_MAGICKEXPORTIMAGEPIXELS */
{
size_t image_height;
MagickRealType color_scale = 65535.0 / (MagickRealType) QuantumRange;
double quantum_range = QuantumRange;
MagickRealType color_scale = 65535.0 / quantum_range;
#ifdef USE_CAIRO
data = xmalloc (width * height * 4);
color_scale /= 256;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment