Index: fpdfsdk/fpdf_flatten.cpp |
diff --git a/fpdfsdk/fpdf_flatten.cpp b/fpdfsdk/fpdf_flatten.cpp |
index 54e606397fb7c9400f5d1cd6173a41aacad4e2b5..e445d9abfa62e560ded266035db7d39ed0df3f33 100644 |
--- a/fpdfsdk/fpdf_flatten.cpp |
+++ b/fpdfsdk/fpdf_flatten.cpp |
@@ -393,7 +393,7 @@ DLLEXPORT int STDCALL FPDFPage_Flatten(FPDF_PAGE page, int nFlag) { |
char sExtend[5] = {}; |
FXSYS_itoa(iKey, sExtend, 10); |
key = CFX_ByteString("FFT") + CFX_ByteString(sExtend); |
- if (!pPageXObject->KeyExist(key.AsStringC())) |
+ if (!pPageXObject->KeyExist(key)) |
break; |
} |
} |
@@ -403,7 +403,7 @@ DLLEXPORT int STDCALL FPDFPage_Flatten(FPDF_PAGE page, int nFlag) { |
CPDF_Dictionary* pNewXORes = NULL; |
if (!key.IsEmpty()) { |
- pPageXObject->SetAtReference(key.AsStringC(), pDocument, dwObjNum); |
+ pPageXObject->SetAtReference(key, pDocument, dwObjNum); |
CPDF_Dictionary* pNewOXbjectDic = pNewXObject->GetDict(); |
pNewXORes = new CPDF_Dictionary; |
pNewOXbjectDic->SetAt("Resources", pNewXORes); |
@@ -435,7 +435,7 @@ DLLEXPORT int STDCALL FPDFPage_Flatten(FPDF_PAGE page, int nFlag) { |
continue; |
if (!sAnnotState.IsEmpty()) { |
- pAPStream = pAPDic->GetStreamBy(sAnnotState.AsStringC()); |
+ pAPStream = pAPDic->GetStreamBy(sAnnotState); |
} else { |
auto it = pAPDic->begin(); |
if (it != pAPDic->end()) { |
@@ -484,7 +484,7 @@ DLLEXPORT int STDCALL FPDFPage_Flatten(FPDF_PAGE page, int nFlag) { |
CFX_ByteString sFormName; |
sFormName.Format("F%d", i); |
uint32_t dwObjNum = pDocument->AddIndirectObject(pObj); |
- pXObject->SetAtReference(sFormName.AsStringC(), pDocument, dwObjNum); |
+ pXObject->SetAtReference(sFormName, pDocument, dwObjNum); |
CPDF_StreamAcc acc; |
acc.LoadAllData(pNewXObject); |