Skip to content

Commit

Permalink
Also skip writing the exif/tiff resolution properties when the pHYs c…
Browse files Browse the repository at this point in the history
…hunk is written.
  • Loading branch information
dlemstra committed Apr 15, 2023
1 parent 132deb9 commit b5b3c7c
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion coders/png.c
Original file line number Diff line number Diff line change
Expand Up @@ -11633,7 +11633,13 @@ static MagickBooleanType WriteOnePNGImage(MngInfo *mng_info,
continue;
/* Suppress density and units if we wrote a pHYs chunk */
if ((ping_exclude_pHYs == MagickFalse) && (
((LocaleCompare(property,"density") == 0) ||
((LocaleCompare(property,"exif:ResolutionUnit") == 0) ||
(LocaleCompare(property,"exif:XResolution") == 0) ||
(LocaleCompare(property,"exif:YResolution") == 0) ||
(LocaleCompare(property,"tiff:ResolutionUnit") == 0) ||
(LocaleCompare(property,"tiff:XResolution") == 0) ||
(LocaleCompare(property,"tiff:YResolution") == 0) ||
(LocaleCompare(property,"density") == 0) ||
(LocaleCompare(property,"units") == 0))))
continue;
/* Suppress the IM-generated date:create and date:modify */
Expand Down

0 comments on commit b5b3c7c

Please sign in to comment.