diff options
author | Thomas Deutschmann <whissi@gentoo.org> | 2020-09-10 18:10:49 +0200 |
---|---|---|
committer | Thomas Deutschmann <whissi@gentoo.org> | 2020-09-11 20:06:36 +0200 |
commit | acfc02c1747065fe450c7cfeb6f1844b62335f08 (patch) | |
tree | 5887806a2e6b99bbb0255e013a9028810e230a7f /base/gxccache.c | |
parent | Import Ghostscript 9.52 (diff) | |
download | ghostscript-gpl-patches-acfc02c1747065fe450c7cfeb6f1844b62335f08.tar.gz ghostscript-gpl-patches-acfc02c1747065fe450c7cfeb6f1844b62335f08.tar.bz2 ghostscript-gpl-patches-acfc02c1747065fe450c7cfeb6f1844b62335f08.zip |
Import Ghostscript 9.53ghostscript-9.53
Signed-off-by: Thomas Deutschmann <whissi@gentoo.org>
Diffstat (limited to 'base/gxccache.c')
-rw-r--r-- | base/gxccache.c | 27 |
1 files changed, 14 insertions, 13 deletions
diff --git a/base/gxccache.c b/base/gxccache.c index 3190cebe..e4f4364c 100644 --- a/base/gxccache.c +++ b/base/gxccache.c @@ -1,4 +1,4 @@ -/* Copyright (C) 2001-2019 Artifex Software, Inc. +/* Copyright (C) 2001-2020 Artifex Software, Inc. All Rights Reserved. This software is provided AS-IS with no warranty, either express or @@ -120,11 +120,11 @@ gx_lookup_fm_pair(gs_font * pfont, const gs_matrix *char_tm, if (pair->font == 0) { pair->font = pfont; - if_debug2m('k', pfont->memory, "[k]updating pair 0x%lx with font 0x%lx\n", - (ulong) pair, (ulong) pfont); + if_debug2m('k', pfont->memory, "[k]updating pair "PRI_INTPTR" with font "PRI_INTPTR"\n", + (intptr_t)pair, (intptr_t)pfont); } else { - if_debug2m('k', pfont->memory, "[k]found pair 0x%lx: font=0x%lx\n", - (ulong) pair, (ulong) pair->font); + if_debug2m('k', pfont->memory, "[k]found pair "PRI_INTPTR": font="PRI_INTPTR"\n", + (intptr_t)pair, (intptr_t)pair->font); } code = gx_touch_fm_pair(dir, pair); if (code < 0) @@ -158,8 +158,8 @@ gx_lookup_cached_char(const gs_font * pfont, const cached_fm_pair * pair, cc->wmode == wmode && cc_depth(cc) == depth ) { if_debug4m('K', pfont->memory, - "[K]found 0x%lx (depth=%d) for glyph=0x%lx, wmode=%d\n", - (ulong) cc, cc_depth(cc), (ulong) glyph, wmode); + "[K]found "PRI_INTPTR" (depth=%d) for glyph=0x%lx, wmode=%d\n", + (intptr_t)cc, cc_depth(cc), (ulong)glyph, wmode); return cc; } chi++; @@ -211,7 +211,8 @@ gx_image_cached_char(register gs_show_enum * penum, register cached_char * cc) "[K]bits"); else dmputs(penum->memory, "[K]no bits\n"); - dmlprintf3(penum->memory, "[K]copying 0x%lx, offset=(%g,%g)\n", (ulong) cc, + dmlprintf3(penum->memory, "[K]copying "PRI_INTPTR", offset=(%g,%g)\n", + (intptr_t) cc, fixed2float(-cc->offset.x), fixed2float(-cc->offset.y)); dmlprintf6(penum->memory, " at (%g,%g)+(%d,%d)->(%d,%d)\n", @@ -256,8 +257,8 @@ gx_image_cached_char(register gs_show_enum * penum, register cached_char * cc) imaging_dev, cx, cy, pdevc->colors.pure, 0); if_debug8m('K', penum->memory, - "[K]render_char display: xfont=0x%lx, glyph=0x%lx\n\tdev=0x%lx(%s) x,y=%d,%d, color=0x%lx => %d\n", - (ulong) xf, (ulong) xg, (ulong) imaging_dev, + "[K]render_char display: xfont="PRI_INTPTR", glyph=0x%lx\n\tdev="PRI_INTPTR"(%s) x,y=%d,%d, color=0x%lx => %d\n", + (intptr_t)xf, (ulong)xg, (intptr_t)imaging_dev, imaging_dev->dname, cx, cy, (ulong) pdevc->colors.pure, code); if (code == 0) @@ -274,8 +275,8 @@ gx_image_cached_char(register gs_show_enum * penum, register cached_char * cc) (gx_device *) & mdev, cx - x, cy - y, (gx_color_index) 1, 1); if_debug7m('K', penum->memory, - "[K]render_char to bits: xfont=0x%lx, glyph=0x%lx\n\tdev=0x%lx(%s) x,y=%d,%d => %d\n", - (ulong) xf, (ulong) xg, (ulong) & mdev, + "[K]render_char to bits: xfont="PRI_INTPTR", glyph=0x%lx\n\tdev="PRI_INTPTR"(%s) x,y=%d,%d => %d\n", + (intptr_t)xf, (ulong) xg, (intptr_t)&mdev, mdev.dname, cx - x, cy - y, code); if (code != 0) return_check_interrupt(penum->memory, 1); @@ -410,7 +411,7 @@ compress_alpha_bits(const cached_char * cc, gs_memory_t * mem) uint sskip = sraster - ((width * depth + 7) >> 3); uint draster = bitmap_raster(width); uint dskip = draster - ((width + 7) >> 3); - byte *mask = gs_alloc_bytes(mem, draster * height, + byte *mask = gs_alloc_bytes(mem, (size_t)draster * height, "compress_alpha_bits"); const byte *sptr = data; byte *dptr = mask; |