[poppler] poppler/poppler: Page.cc,1.16,1.17

Albert Astals Cid aacid at kemper.freedesktop.org
Wed Mar 7 11:15:34 PST 2007


Update of /cvs/poppler/poppler/poppler
In directory kemper:/tmp/cvs-serv13217/poppler

Modified Files:
	Page.cc 
Log Message:
2007-03-07  Carlos Garcia Campos <carlosgc at gnome.org>
        reviewed by: Albert Astals Cid <aacid at kde.org>

        * poppler/Page.cc: Consider 0x0 boxes as invalid. Fixes
        http://bugzilla.gnome.org/show_bug.cgi?id=408682

2007-03-06  Pino Toscano <pino at kde.org>
        reviewed by: Albert Astals Cid <aacid at kde.org>

       * configure.ac:
       * qt/Makefile.am:
       * qt/poppler-link.cc:
       * qt/poppler-page.cc:
       * qt/poppler-private.h:
       * qt4/poppler-link.cc:
       Make the Qt4 frontend compilable again with no Splash.
       Make the Qt3 frontend compilable with no Splash.


Index: Page.cc
===================================================================
RCS file: /cvs/poppler/poppler/poppler/Page.cc,v
retrieving revision 1.16
retrieving revision 1.17
diff -u -d -r1.16 -r1.17
--- Page.cc	24 Feb 2007 23:32:23 -0000	1.16
+++ Page.cc	7 Mar 2007 19:15:32 -0000	1.17
@@ -39,6 +39,7 @@
 
 PageAttrs::PageAttrs(PageAttrs *attrs, Dict *dict) {
   Object obj1;
+  PDFRectangle mBox;
 
   // get old/default values
   if (attrs) {
@@ -61,7 +62,9 @@
   }
 
   // media box
-  readBox(dict, "MediaBox", &mediaBox);
+  if (readBox(dict, "MediaBox", &mBox)) {
+    mediaBox = mBox;
+  }
 
   // crop box
   if (readBox(dict, "CropBox", &cropBox)) {
@@ -170,6 +173,8 @@
       ok = gFalse;
     }
     obj2.free();
+    if (tmp.x1 == 0 && tmp.x2 == 0 && tmp.y1 == 0 && tmp.y2 == 0)
+      ok = gFalse;
     if (ok) {
       if (tmp.x1 > tmp.x2) {
 	t = tmp.x1; tmp.x1 = tmp.x2; tmp.x2 = t;



More information about the poppler mailing list