summaryrefslogtreecommitdiff
path: root/fpdfsdk
diff options
context:
space:
mode:
authorHenrique Nakashima <hnakashima@chromium.org>2017-06-19 16:04:34 -0400
committerChromium commit bot <commit-bot@chromium.org>2017-06-19 20:44:58 +0000
commitb73ce7bcd72a97c780176d9f63681a5415c06422 (patch)
tree2e0b3b4f2996344101b9af67ce761708255b05ef /fpdfsdk
parentd3610056e36b9211e9ed3806a3f99a1184e9413e (diff)
downloadpdfium-b73ce7bcd72a97c780176d9f63681a5415c06422.tar.xz
Fixing metadata not read from linearized file.chromium/3136
This still won't work if the info dict is not on the first page without first calling FPDFAvail_IsFormAvail or FPDFAvail_IsPageAvail, as these are the methods that trigger parsing the rest of the data. Bug: pdfium:664 Change-Id: I0b0193e415a1153dcfb8bfba0e0482da6b6ba53c Reviewed-on: https://pdfium-review.googlesource.com/6610 Commit-Queue: Henrique Nakashima <hnakashima@chromium.org> Reviewed-by: dsinclair <dsinclair@chromium.org> Reviewed-by: Nicolás Peña <npm@chromium.org>
Diffstat (limited to 'fpdfsdk')
-rw-r--r--fpdfsdk/fpdfdoc.cpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/fpdfsdk/fpdfdoc.cpp b/fpdfsdk/fpdfdoc.cpp
index 1c445e6f14..7be53a6554 100644
--- a/fpdfsdk/fpdfdoc.cpp
+++ b/fpdfsdk/fpdfdoc.cpp
@@ -394,6 +394,7 @@ DLLEXPORT unsigned long STDCALL FPDF_GetMetaText(FPDF_DOCUMENT document,
CPDF_Document* pDoc = CPDFDocumentFromFPDFDocument(document);
if (!pDoc)
return 0;
+ pDoc->LoadDocumentInfo();
CPDF_Dictionary* pInfo = pDoc->GetInfo();
if (!pInfo)
return 0;