From 09fea1568ee2854743ec047578122eb294094893 Mon Sep 17 00:00:00 2001 From: Jason Crain Date: Mon, 1 Jul 2013 02:24:47 -0500 Subject: [PATCH] Check for NULL in Page::getResourceDictCopy --- poppler/Page.cc | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/poppler/Page.cc b/poppler/Page.cc index 426a15d..02712d6 100644 --- a/poppler/Page.cc +++ b/poppler/Page.cc @@ -363,7 +363,8 @@ Dict *Page::getResourceDict() { Dict *Page::getResourceDictCopy(XRef *xrefA) { pageLocker(); - return attrs->getResourceDict()->copy(xrefA); + Dict *dict = attrs->getResourceDict(); + return dict ? dict->copy(xrefA) : NULL; } void Page::replaceXRef(XRef *xrefA) { -- 1.7.10.4