From a0ebcadd4fadabbe375efbc55445ac80d6d98d79 Mon Sep 17 00:00:00 2001 From: Adrian Johnson Date: Mon, 6 Feb 2012 16:50:11 +1030 Subject: [PATCH] cairo: don't read inline image streams twice Bug 45668 --- poppler/CairoOutputDev.cc | 3 ++- 1 files changed, 2 insertions(+), 1 deletions(-) diff --git a/poppler/CairoOutputDev.cc b/poppler/CairoOutputDev.cc index 7ef36df..d59da96 100644 --- a/poppler/CairoOutputDev.cc +++ b/poppler/CairoOutputDev.cc @@ -2759,7 +2759,8 @@ void CairoOutputDev::drawImage(GfxState *state, Object *ref, Stream *str, cairo_surface_mark_dirty (image); - setMimeData(str, ref, image); + if (!inlineImg) /* don't read stream twice if it is an inline image */ + setMimeData(str, ref, image); pattern = cairo_pattern_create_for_surface (image); cairo_surface_destroy (image); -- 1.7.5.4