Crash issue when using FPDFBookmark_GetDest and FPDFDest_GetDestPageIndex on Linux-musl-arm64 with version 144.0.7543.0
4 views
Skip to first unread message
tan zhiyuan
unread,
1:49 PM (7 hours ago) 1:49 PM
Reply to author
Sign in to reply to author
Forward
Sign in to forward
Delete
You do not have permission to delete messages in this group
Copy link
Report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to pdfium
When using the PDFium library built for Linux-musl-arm64 in a HarmonyOS mobile application, the following code snippet: FPDF_DEST dest = FPDFBookmark_GetDest(doc, bookmark); if (dest) { int destPageIdx = FPDFDest_GetDestPageIndex(doc, dest); if (destPageIdx >= 0) { return static_cast(destPageIdx); } } causes the application to crash. Specifically, after recursively invoking FPDFBookmark_GetDest and FPDFDest_GetDestPageIndex more than eight times, a crash occurs due to null pointer dereference or invalid (wild) pointer access.