summaryrefslogtreecommitdiff
path: root/libs/hwui
diff options
context:
space:
mode:
authorHaibo Huang <hhb@google.com>2020-04-28 14:47:47 -0700
committerHaibo Huang <hhb@google.com>2020-05-07 22:01:01 +0000
commita2588f766f59029cd26faa96a135e8b43a62cca8 (patch)
treedb3831225ca42a4b622924c33fe178372e38afbc /libs/hwui
parent3369bbd82a5498e50b39a1f3fdc78f9c3f5022ef (diff)
Fix the use of pdfium
FPDF_LoadPage returns FPDF_PAGE and that's also what expected by other APIs. There's no need for conversion. This works now because FPDF_PAGE is defined as void*. But will fails with new pdfium. Bug: 155031873 Change-Id: I74381ec8ec36797a5901ea3de845c2b5d798ba0c (cherry picked from commit 24fca180a146ec6e94a5058280c593216edbae15)
Diffstat (limited to 'libs/hwui')
-rw-r--r--libs/hwui/jni/pdf/PdfEditor.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/libs/hwui/jni/pdf/PdfEditor.cpp b/libs/hwui/jni/pdf/PdfEditor.cpp
index 828d6e3992b6..e65921ac8e0a 100644
--- a/libs/hwui/jni/pdf/PdfEditor.cpp
+++ b/libs/hwui/jni/pdf/PdfEditor.cpp
@@ -110,7 +110,7 @@ static void nativeSetTransformAndClip(JNIEnv* env, jclass thiz, jlong documentPt
jlong transformPtr, jint clipLeft, jint clipTop, jint clipRight, jint clipBottom) {
FPDF_DOCUMENT document = reinterpret_cast<FPDF_DOCUMENT>(documentPtr);
- FPDF_PAGE* page = (FPDF_PAGE*) FPDF_LoadPage(document, pageIndex);
+ FPDF_PAGE page = FPDF_LoadPage(document, pageIndex);
if (!page) {
jniThrowException(env, "java/lang/IllegalStateException",
"cannot open page");