| Index: core/src/fpdfapi/fpdf_page/fpdf_page_parser.cpp
|
| diff --git a/core/src/fpdfapi/fpdf_page/fpdf_page_parser.cpp b/core/src/fpdfapi/fpdf_page/fpdf_page_parser.cpp
|
| index d3e3807046fa7a9ec5a7ecb89904c586c3809b85..7091b207ffbbefe85c1507dd00355746aa5b947d 100644
|
| --- a/core/src/fpdfapi/fpdf_page/fpdf_page_parser.cpp
|
| +++ b/core/src/fpdfapi/fpdf_page/fpdf_page_parser.cpp
|
| @@ -496,9 +496,11 @@ void PDF_ReplaceAbbr(CPDF_Object* pObj) {
|
| switch (pObj->GetType()) {
|
| case PDFOBJ_DICTIONARY: {
|
| CPDF_Dictionary* pDict = pObj->AsDictionary();
|
| - for (const auto& it : *pDict) {
|
| - CFX_ByteString key = it.first;
|
| - CPDF_Object* value = it.second;
|
| + auto it = pDict->begin();
|
| + while (it != pDict->end()) {
|
| + auto old_it = it++;
|
| + CFX_ByteString key = old_it->first;
|
| + CPDF_Object* value = old_it->second;
|
| CFX_ByteStringC fullname = PDF_FindFullName(
|
| PDF_InlineKeyAbbr, FX_ArraySize(PDF_InlineKeyAbbr), key);
|
| if (!fullname.IsEmpty()) {
|
| @@ -543,9 +545,11 @@ void PDF_ReplaceFull(CPDF_Object* pObj) {
|
| switch (pObj->GetType()) {
|
| case PDFOBJ_DICTIONARY: {
|
| CPDF_Dictionary* pDict = pObj->AsDictionary();
|
| - for (const auto& it : *pDict) {
|
| - CFX_ByteString key = it.first;
|
| - CPDF_Object* value = it.second;
|
| + auto it = pDict->begin();
|
| + while (it != pDict->end()) {
|
| + auto old_it = it++;
|
| + CFX_ByteString key = old_it->first;
|
| + CPDF_Object* value = old_it->second;
|
| CFX_ByteStringC abbrName = PDF_FindAbbrName(
|
| PDF_InlineKeyAbbr, FX_ArraySize(PDF_InlineKeyAbbr), key);
|
| if (!abbrName.IsEmpty()) {
|
|
|