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

Side by Side Diff: core/src/fpdfapi/fpdf_parser/fpdf_parser_parser.cpp

Issue 665223003: Resolve compilation error with G++ 4.9. (Closed) Base URL: https://pdfium.googlesource.com/pdfium.git@master
Patch Set: Take Jun's suggestion. Created 6 years, 1 month 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 unified diff | Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 PDFium Authors. All rights reserved. 1 // Copyright 2014 PDFium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com 5 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com
6 6
7 #include "../../../include/fpdfapi/fpdf_parser.h" 7 #include "../../../include/fpdfapi/fpdf_parser.h"
8 #include "../../../include/fpdfapi/fpdf_module.h" 8 #include "../../../include/fpdfapi/fpdf_module.h"
9 #include "../../../include/fpdfapi/fpdf_page.h" 9 #include "../../../include/fpdfapi/fpdf_page.h"
10 #include "../../../../third_party/numerics/safe_math.h" 10 #include "../../../../third_party/numerics/safe_math.h"
(...skipping 2174 matching lines...) Expand 10 before | Expand all | Expand 10 after
2185 } 2185 }
2186 nKeys ++; 2186 nKeys ++;
2187 key = PDF_NameDecode(key); 2187 key = PDF_NameDecode(key);
2188 if (key == FX_BSTRC("/Contents")) { 2188 if (key == FX_BSTRC("/Contents")) {
2189 dwSignValuePos = m_Pos; 2189 dwSignValuePos = m_Pos;
2190 } 2190 }
2191 CPDF_Object* pObj = GetObject(pObjList, objnum, gennum, level + 1); 2191 CPDF_Object* pObj = GetObject(pObjList, objnum, gennum, level + 1);
2192 if (pObj == NULL) { 2192 if (pObj == NULL) {
2193 continue; 2193 continue;
2194 } 2194 }
2195 if (key.GetLength() == 1) { 2195 if (key.GetLength() >= 1) {
2196 pDict->SetAt(CFX_ByteStringC(((FX_LPCSTR)key) + 1, key.GetLength () - 1), pObj);
2197 } else {
2198 if (nKeys < 32) { 2196 if (nKeys < 32) {
2199 pDict->SetAt(CFX_ByteStringC(((FX_LPCSTR)key) + 1, key.GetLe ngth() - 1), pObj); 2197 pDict->SetAt(CFX_ByteStringC(((FX_LPCSTR)key) + 1, key.GetLe ngth() - 1), pObj);
2200 } else { 2198 } else {
2201 pDict->AddValue(CFX_ByteStringC(((FX_LPCSTR)key) + 1, key.Ge tLength() - 1), pObj); 2199 pDict->AddValue(CFX_ByteStringC(((FX_LPCSTR)key) + 1, key.Ge tLength() - 1), pObj);
2202 } 2200 }
2203 } 2201 }
2204 } 2202 }
2205 if (IsSignatureDict(pDict)) { 2203 if (IsSignatureDict(pDict)) {
2206 FX_FILESIZE dwSavePos = m_Pos; 2204 FX_FILESIZE dwSavePos = m_Pos;
2207 m_Pos = dwSignValuePos; 2205 m_Pos = dwSignValuePos;
(...skipping 2225 matching lines...) Expand 10 before | Expand all | Expand 10 after
4433 { 4431 {
4434 FX_INT32 iSize = m_childNode.GetSize(); 4432 FX_INT32 iSize = m_childNode.GetSize();
4435 for (FX_INT32 i = 0; i < iSize; ++i) { 4433 for (FX_INT32 i = 0; i < iSize; ++i) {
4436 CPDF_PageNode *pNode = (CPDF_PageNode*)m_childNode[i]; 4434 CPDF_PageNode *pNode = (CPDF_PageNode*)m_childNode[i];
4437 if (pNode) { 4435 if (pNode) {
4438 delete pNode; 4436 delete pNode;
4439 } 4437 }
4440 } 4438 }
4441 m_childNode.RemoveAll(); 4439 m_childNode.RemoveAll();
4442 } 4440 }
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698