summaryrefslogtreecommitdiff
path: root/draw/draw_glyph.c
diff options
context:
space:
mode:
authorTor Andersson <tor.andersson@artifex.com>2011-09-21 17:29:51 +0200
committerTor Andersson <tor.andersson@artifex.com>2011-09-21 17:29:51 +0200
commitf783c31203be2dbd7a28c89557014f97a367bec9 (patch)
tree8faea8d21fa44b99226af34a13f33c6a0e1f7182 /draw/draw_glyph.c
parentaa7668835afffd5a2a496a60ed6edb672f5af1a7 (diff)
downloadmupdf-f783c31203be2dbd7a28c89557014f97a367bec9.tar.xz
Add warning context.
Diffstat (limited to 'draw/draw_glyph.c')
-rw-r--r--draw/draw_glyph.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/draw/draw_glyph.c b/draw/draw_glyph.c
index 1d94f767..6cb1518a 100644
--- a/draw/draw_glyph.c
+++ b/draw/draw_glyph.c
@@ -59,7 +59,7 @@ void
fz_free_glyph_cache(fz_context *ctx, fz_glyph_cache *cache)
{
fz_evict_glyph_cache(ctx, cache);
- fz_free_hash(ctx, cache->hash);
+ fz_free_hash(cache->hash);
fz_free(ctx, cache);
}
@@ -81,7 +81,7 @@ fz_render_glyph(fz_context *ctx, fz_glyph_cache *cache, fz_font *font, int gid,
if (size > MAX_FONT_SIZE)
{
/* TODO: this case should be handled by rendering glyph as a path fill */
- fz_warn("font size too large (%g), not rendering glyph", size);
+ fz_warn(ctx, "font size too large (%g), not rendering glyph", size);
return NULL;
}
@@ -112,7 +112,7 @@ fz_render_glyph(fz_context *ctx, fz_glyph_cache *cache, fz_font *font, int gid,
}
else
{
- fz_warn("assert: uninitialized font structure");
+ fz_warn(ctx, "assert: uninitialized font structure");
return NULL;
}
@@ -123,7 +123,7 @@ fz_render_glyph(fz_context *ctx, fz_glyph_cache *cache, fz_font *font, int gid,
if (cache->total + val->w * val->h > MAX_CACHE_SIZE)
fz_evict_glyph_cache(ctx, cache);
fz_keep_font(key.font);
- fz_hash_insert(ctx, cache->hash, &key, val);
+ fz_hash_insert(cache->hash, &key, val);
cache->total += val->w * val->h;
return fz_keep_pixmap(val);
}