]> www.fi.muni.cz Git - evince.git/blobdiff - pdf/xpdf/PDFDoc.h
Fix for a number of integer overflow bugs discovered by Chris Evans.
[evince.git] / pdf / xpdf / PDFDoc.h
index ea73282b6437b195a550738620198117c4175864..57e37a2afb7d4847904fb0e22ecd07415b5d52d5 100644 (file)
@@ -80,8 +80,8 @@ public:
   Object *getStructTreeRoot() { return catalog->getStructTreeRoot(); }
 
   // Display a page.
-  void displayPage(OutputDev *out, int page, double zoom,
-                  int rotate, GBool doLinks,
+  void displayPage(OutputDev *out, int page, double hDPI, double vDPI,
+                  int rotate, GBool crop, GBool doLinks,
                   GBool (*abortCheckCbk)(void *data) = NULL,
                   void *abortCheckCbkData = NULL,
                    GBool (*annotDisplayDecideCbk)(Annot *annot, void *user_data) = NULL,
@@ -89,16 +89,18 @@ public:
 
   // Display a range of pages.
   void displayPages(OutputDev *out, int firstPage, int lastPage,
-                   int zoom, int rotate, GBool doLinks,
+                   double hDPI, double vDPI, int rotate,
+                   GBool crop, GBool doLinks,
                    GBool (*abortCheckCbk)(void *data) = NULL,
                    void *abortCheckCbkData = NULL,
                     GBool (*annotDisplayDecideCbk)(Annot *annot, void *user_data) = NULL,
                     void *annotDisplayDecideCbkData = NULL);
 
   // Display part of a page.
-  void displayPageSlice(OutputDev *out, int page, double zoom,
-                       int rotate, int sliceX, int sliceY,
-                       int sliceW, int sliceH,
+  void displayPageSlice(OutputDev *out, int page,
+                       double hDPI, double vDPI,
+                       int rotate, GBool crop,
+                       int sliceX, int sliceY, int sliceW, int sliceH,
                        GBool (*abortCheckCbk)(void *data) = NULL,
                        void *abortCheckCbkData = NULL,
                         GBool (*annotDisplayDecideCbk)(Annot *annot, void *user_data) = NULL,
@@ -110,7 +112,8 @@ public:
 
   // If point <x>,<y> is in a link, return the associated action;
   // else return NULL.
-  LinkAction *findLink(double x, double y) { return links->find(x, y); }
+  LinkAction *findLink(double x, double y)
+    { return links ? links->find(x, y) : (LinkAction *)NULL; }
 
   // Return true if <x>,<y> is in a link.
   GBool onLink(double x, double y) { return links->onLink(x, y); }