qt4/src/poppler-private.cc | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-)
New commits: commit 64e157c7acc921b7acccc1046fbbf9232bf0b74c Author: Albert Astals Cid <[email protected]> Date: Fri Jan 28 20:34:08 2011 +0000 Make sure uMap is still valid before using it Fixes KDE bug 264667 diff --git a/qt4/src/poppler-private.cc b/qt4/src/poppler-private.cc index da19e98..253222e 100644 --- a/qt4/src/poppler-private.cc +++ b/qt4/src/poppler-private.cc @@ -1,6 +1,6 @@ /* poppler-private.cc: qt interface to poppler * Copyright (C) 2005, Net Integration Technologies, Inc. - * Copyright (C) 2006 by Albert Astals Cid <[email protected]> + * Copyright (C) 2006, 2011 by Albert Astals Cid <[email protected]> * Copyright (C) 2008, 2010, 2011 by Pino Toscano <[email protected]> * Inspired on code by * Copyright (C) 2004 by Albert Astals Cid <[email protected]> @@ -71,11 +71,13 @@ namespace Debug { QString unicodeToQString(Unicode* u, int len) { static UnicodeMap *uMap = 0; - if (!uMap) + static GlobalParams *gParams = globalParams; + if (!uMap || gParams != globalParams) { GooString enc("UTF-8"); uMap = globalParams->getUnicodeMap(&enc); uMap->incRefCnt(); + gParams = globalParams; } // ignore the last character if it is 0x0 _______________________________________________ poppler mailing list [email protected] http://lists.freedesktop.org/mailman/listinfo/poppler
