From: Johan Engelen Date: Sat, 23 Oct 2010 17:19:19 +0000 (+0200) Subject: fix crash bug: PDF export: crash in 'CairoRenderContext::_showGlyphs' X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=d07caeb4fe990f046815fb7bb497677b57ba0712;p=inkscape.git fix crash bug: PDF export: crash in 'CairoRenderContext::_showGlyphs' --- diff --git a/src/extension/internal/cairo-render-context.cpp b/src/extension/internal/cairo-render-context.cpp index 098c56a79..2e5ab295e 100644 --- a/src/extension/internal/cairo-render-context.cpp +++ b/src/extension/internal/cairo-render-context.cpp @@ -1480,18 +1480,19 @@ CairoRenderContext::_showGlyphs(cairo_t *cr, PangoFont *font, std::vector::const_iterator it_info = glyphtext.begin() ; it_info != glyphtext.end() ; it_info++) { // skip glyphs which are PANGO_GLYPH_EMPTY (0x0FFFFFFF) // or have the PANGO_GLYPH_UNKNOWN_FLAG (0x10000000) set if (it_info->index == 0x0FFFFFFF || it_info->index & 0x10000000) { TRACE(("INVALID GLYPH found\n")); + g_message("Invalid glyph found, continuing..."); num_invalid_glyphs++; continue; } - glyphs[i - num_invalid_glyphs].index = it_info->index; - glyphs[i - num_invalid_glyphs].x = it_info->x; - glyphs[i - num_invalid_glyphs].y = it_info->y; + glyphs[i].index = it_info->index; + glyphs[i].x = it_info->x; + glyphs[i].y = it_info->y; i++; }