Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(691)

Unified Diff: fpdfsdk/src/fpdf_ext.cpp

Issue 1274803004: Merge to XFA: Remove dead code from CPDF_Metadata. Add missing nullptr check. (Closed) Base URL: https://pdfium.googlesource.com/pdfium@xfa
Patch Set: Created 5 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « core/src/fpdfdoc/doc_metadata.cpp ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: fpdfsdk/src/fpdf_ext.cpp
diff --git a/fpdfsdk/src/fpdf_ext.cpp b/fpdfsdk/src/fpdf_ext.cpp
index a198f9f63cf129fc4682afab8923c5077e24e224..210c28dc431853735698ff44caa35d5a69285a16 100644
--- a/fpdfsdk/src/fpdf_ext.cpp
+++ b/fpdfsdk/src/fpdf_ext.cpp
@@ -89,7 +89,7 @@ void CheckUnSupportAnnot(CPDF_Document* pDoc, CPDF_Annot* pPDFAnnot) {
}
}
-FX_BOOL CheckSharedForm(CXML_Element* pElement, CFX_ByteString cbName) {
+FX_BOOL CheckSharedForm(const CXML_Element* pElement, CFX_ByteString cbName) {
int count = pElement->CountAttrs();
int i = 0;
for (i = 0; i < count; i++) {
@@ -169,9 +169,8 @@ void CheckUnSupportError(CPDF_Document* pDoc, FX_DWORD err_code) {
}
// SharedForm
- CPDF_Metadata metaData;
- metaData.LoadDoc(pDoc);
- CXML_Element* pElement = metaData.GetRoot();
+ CPDF_Metadata metaData(pDoc);
+ const CXML_Element* pElement = metaData.GetRoot();
if (pElement)
CheckSharedForm(pElement, "workflowType");
}
« no previous file with comments | « core/src/fpdfdoc/doc_metadata.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698