[ps] Check for an empty font subset.

Return early before trying to emit an empty subset into the document -
avoids a potential use of an uninitialised status variable.
This commit is contained in:
Chris Wilson 2008-10-21 10:42:41 +01:00
parent fd1f3c27e0
commit 29da47be60

View file

@ -480,6 +480,9 @@ _cairo_ps_surface_emit_type3_font_subset (cairo_ps_surface_t *surface,
cairo_surface_t *type3_surface;
double width;
if (font_subset->num_glyphs == 0)
return CAIRO_STATUS_SUCCESS;
#if DEBUG_PS
_cairo_output_stream_printf (surface->final_stream,
"%% _cairo_ps_surface_emit_type3_font_subset\n");