From: Bastian Germann <bage@debian.org>
      Andreas Tille <tille@debian.org>
Date: 2025-09-11
Subject: Prevent incompatible pointer types
         + include header instead of (wrong) declaration of function
---
 src/source/proof.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

--- a/src/source/proof.c
+++ b/src/source/proof.c
@@ -29,6 +29,7 @@
 #include <evince-document.h>
 #endif
 
+#include <libdocument/ev-document-annotations.h>
 static const gchar *nearest_annotation_text = NULL;
 static GList *annotated_pages = NULL;
 static GList *current_page;
@@ -279,8 +280,7 @@ press (EvView * view,  GdkEventButton  *
     if (event->button != 1)
         infodialog (help_text);
     nearest_annotation_text = NULL;
-    extern EvMappingList * ev_document_annotations_get_annotations();
-    EvMappingList *mapping_list = ev_document_annotations_get_annotations (doc, ev_document_get_page(doc, i));
+    EvMappingList *mapping_list = ev_document_annotations_get_annotations (EV_DOCUMENT_ANNOTATIONS(doc), ev_document_get_page(doc, i));
     if(mapping_list)
     {
     gdouble nearest = G_MAXDOUBLE;
@@ -312,8 +312,7 @@ find_annotated_pages (EvDocumentModel *m
     gint i;
     for (i=0; i< ev_document_get_n_pages(doc);i++)
         {
-            extern EvMappingList * ev_document_annotations_get_annotations();
-            EvMappingList *mapping_list = ev_document_annotations_get_annotations (doc, ev_document_get_page(doc, i));
+            EvMappingList *mapping_list = ev_document_annotations_get_annotations (EV_DOCUMENT_ANNOTATIONS(doc), ev_document_get_page(doc, i));
             if(mapping_list)
             {
              annotated_pages = g_list_append (annotated_pages, GINT_TO_POINTER(i));
