pdf2djvu/pdf2djvu-Destination-copy-c...

29 lines
940 B
Diff
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

From 81b635e014ebd0240a8719cc39b6a1b759cc6a98 Mon Sep 17 00:00:00 2001
From: Jakub Wilk <jwilk@jwilk.net>
Date: Wed, 16 Feb 2022 09:10:28 +0000
Subject: main: use pdf::link::Destination copy constructor.
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Fixes:
main.cc: In function int get_page_for_goto_link(pdf::link::GoTo*, pdf::Catalog*):
main.cc:92:27: error: const Destination {aka const class LinkDest} has no member named copy
https://cgit.freedesktop.org/poppler/poppler/commit/?id=7a429c3cf9fba67e
diff --git a/main.cc b/main.cc
index 2b42d16..bb5fd57 100644
--- a/pdf2djvu.cc
+++ b/pdf2djvu.cc
@@ -89,7 +89,7 @@ static int get_page_for_goto_link(pdf::link::GoTo *goto_link, pdf::Catalog *cata
#endif
}
else
- dest.reset(orig_dest->copy());
+ dest.reset(new pdf::link::Destination(*orig_dest));
if (dest.get() != nullptr)
{
int page;