Web   ·   Wiki   ·   Activities   ·   Blog   ·   Lists   ·   Chat   ·   Meeting   ·   Bugs   ·   Git   ·   Translate   ·   Archive   ·   People   ·   Donate
summaryrefslogtreecommitdiffstats
path: root/pdf
diff options
context:
space:
mode:
authorMarco Pesenti Gritti <marco@gnome.org>2005-01-21 09:24:03 (GMT)
committer Marco Pesenti Gritti <marco@src.gnome.org>2005-01-21 09:24:03 (GMT)
commita0ed55c37314448eaa19c4c11198e32ddb899bbc (patch)
tree6ae54ae7a8c5a7eecec85475f5a04e8dfe98b570 /pdf
parent40ea9bf598e586f430db71fc87841184cfafc929 (diff)
Check the links info is initialized before using it. Should fix a crash on
2005-01-21 Marco Pesenti Gritti <marco@gnome.org> * pdf/xpdf/pdf-document.cc: Check the links info is initialized before using it. Should fix a crash on startup.
Diffstat (limited to 'pdf')
-rw-r--r--pdf/xpdf/pdf-document.cc4
1 files changed, 4 insertions, 0 deletions
diff --git a/pdf/xpdf/pdf-document.cc b/pdf/xpdf/pdf-document.cc
index b9180bd..96b1132 100644
--- a/pdf/xpdf/pdf-document.cc
+++ b/pdf/xpdf/pdf-document.cc
@@ -1041,6 +1041,10 @@ pdf_document_get_link (EvDocument *document, int x, int y)
LinkAction *action;
double link_x, link_y;
+ if (pdf_document->links == NULL) {
+ return NULL;
+ }
+
/* Zoom */
link_x = x / pdf_document->scale;
link_y = y / pdf_document->scale;