]> granicus.if.org Git - imagemagick/commitdiff
https://github.com/ImageMagick/ImageMagick/issues/1428
authorCristy <urban-warrior@imagemagick.org>
Sat, 22 Dec 2018 15:12:36 +0000 (10:12 -0500)
committerCristy <urban-warrior@imagemagick.org>
Sat, 22 Dec 2018 15:12:36 +0000 (10:12 -0500)
coders/png.c

index c80b4bcdcdf9935fa5c5c194695c94314e376d6a..6754a6b9b5a706254dbd1431caa5f0eb8151524a 100644 (file)
@@ -8757,6 +8757,7 @@ static MagickBooleanType WriteOnePNGImage(MngInfo *mng_info,
     Sometimes we get PseudoClass images whose RGB values don't match
     the colors in the colormap.  This code syncs the RGB values.
   */
+  image->depth=GetImageQuantumDepth(image,MagickFalse);
   if (image->depth <= 8 && image->taint && image->storage_class == PseudoClass)
      (void) SyncImage(image,exception);