diff options
author | Thomas Deutschmann <whissi@gentoo.org> | 2020-03-19 13:53:45 +0100 |
---|---|---|
committer | Thomas Deutschmann <whissi@gentoo.org> | 2020-08-13 11:28:25 +0200 |
commit | dc2ba49207af71193f1390d84bba4e15aeea0ce0 (patch) | |
tree | 79c2a51cb5fa2b87800b1113e0015a7108cd2eb3 /devices/gdevplan.c | |
parent | Import Ghostscript 9.50 (diff) | |
download | ghostscript-gpl-patches-dc2ba49207af71193f1390d84bba4e15aeea0ce0.tar.gz ghostscript-gpl-patches-dc2ba49207af71193f1390d84bba4e15aeea0ce0.tar.bz2 ghostscript-gpl-patches-dc2ba49207af71193f1390d84bba4e15aeea0ce0.zip |
Import Ghostscript 9.52ghostscript-9.52
Signed-off-by: Thomas Deutschmann <whissi@gentoo.org>
Diffstat (limited to 'devices/gdevplan.c')
-rw-r--r-- | devices/gdevplan.c | 15 |
1 files changed, 14 insertions, 1 deletions
diff --git a/devices/gdevplan.c b/devices/gdevplan.c index b91f61d0..313d08f8 100644 --- a/devices/gdevplan.c +++ b/devices/gdevplan.c @@ -248,13 +248,26 @@ static void dump_row_pnmc(int w, byte **data, gp_file *dump_file) static void dump_row_pbm(int w, byte **data, gp_file *dump_file) { byte *r = data[0]; +#ifdef CLUSTER + int end = w>>3; + byte mask = 255>>(w&7); + if (w & 7) + mask = ~mask; + else + end--; +#else + byte mask = 255; +#endif if (dump_file == NULL) return; + if (w == 0) + return; w = (w+7)>>3; - while (w--) { + while (--w) { gp_fputc(*r++, dump_file); } + gp_fputc(mask & *r, dump_file); } static void dump_row_pgm(int w, byte **data, gp_file *dump_file) |