diff options
author | Chris Wilson <chris@chris-wilson.co.uk> | 2010-07-02 17:01:12 +0100 |
---|---|---|
committer | Chris Wilson <chris@chris-wilson.co.uk> | 2010-07-02 17:02:19 +0100 |
commit | 4c039b1cdfac5b5d6aa0c38f0779213fd14ec7de (patch) | |
tree | 51040747046c00115cc55e983f1305990f783a14 /src/cairo-user-font.c | |
parent | 1f84f5682c6ff246b3d28c75c8731504f31c1ee1 (diff) | |
download | cairo-4c039b1cdfac5b5d6aa0c38f0779213fd14ec7de.tar.gz |
user-font: Check the status before destroying the context
Diffstat (limited to 'src/cairo-user-font.c')
-rw-r--r-- | src/cairo-user-font.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/cairo-user-font.c b/src/cairo-user-font.c index 34638addf..326b804d3 100644 --- a/src/cairo-user-font.c +++ b/src/cairo-user-font.c @@ -136,11 +136,11 @@ _cairo_user_scaled_glyph_init (void *abstract_font, status = face->scaled_font_methods.render_glyph ((cairo_scaled_font_t *)scaled_font, _cairo_scaled_glyph_index(scaled_glyph), cr, &extents); - cairo_destroy (cr); - if (status == CAIRO_STATUS_SUCCESS) status = cairo_status (cr); + cairo_destroy (cr); + if (unlikely (status)) { cairo_surface_destroy (recording_surface); return status; |