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
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.


Reply all
Reply to author
Forward
0 new messages