diff options
author | Vladimir Vukicevic <vladimir@pobox.com> | 2008-01-22 15:32:11 -0800 |
---|---|---|
committer | Vladimir Vukicevic <vladimir@h-232.office.mozilla.org> | 2008-01-22 15:32:11 -0800 |
commit | 02970ac8cf27bc9d42cf27848a97019d9dd13b6d (patch) | |
tree | df9841648694c4ba996a8867c15df763db5bcee0 /src/cairo-surface-fallback.c | |
parent | 1109ccfb4e5b078581a3b4a7e2d152681fa863ec (diff) |
Fix usage of cairo_rectangle_int16_t leading to memory corruption
cairo_rectangle_int16_t was being used in a number of places instead
of cairo_rectangle_int_t, which led to memory corruption when cairo was
using a fixed point format with a bigger space than 16.16 (such as 24.8).
Diffstat (limited to 'src/cairo-surface-fallback.c')
-rw-r--r-- | src/cairo-surface-fallback.c | 9 |
1 files changed, 2 insertions, 7 deletions
diff --git a/src/cairo-surface-fallback.c b/src/cairo-surface-fallback.c index 02a2e9d9..2eb4eae1 100644 --- a/src/cairo-surface-fallback.c +++ b/src/cairo-surface-fallback.c @@ -997,8 +997,7 @@ _cairo_surface_fallback_show_glyphs (cairo_surface_t *surface, return status; if (_cairo_operator_bounded_by_mask (op)) { - cairo_rectangle_int16_t glyph_extents; - cairo_rectangle_int_t glyph_extents_full; + cairo_rectangle_int_t glyph_extents; status = _cairo_scaled_font_glyph_device_extents (scaled_font, glyphs, num_glyphs, @@ -1006,11 +1005,7 @@ _cairo_surface_fallback_show_glyphs (cairo_surface_t *surface, if (status) return status; - glyph_extents_full.x = glyph_extents.x; - glyph_extents_full.y = glyph_extents.y; - glyph_extents_full.width = glyph_extents.width; - glyph_extents_full.height = glyph_extents.height; - _cairo_rectangle_intersect (&extents, &glyph_extents_full); + _cairo_rectangle_intersect (&extents, &glyph_extents); } status = _cairo_clip_intersect_to_rectangle (surface->clip, &extents); |