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

Side by Side Diff: core/fpdfapi/page/fpdf_page_parser_old.cpp

Issue 2449293002: Fix some bool/int mismatches. (Closed)
Patch Set: Created 4 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
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 "core/fpdfapi/page/pageint.h" 7 #include "core/fpdfapi/page/pageint.h"
8 8
9 #include <limits.h> 9 #include <limits.h>
10 10
(...skipping 89 matching lines...) Expand 10 before | Expand all | Expand 10 after
100 dest_buf, dest_size); 100 dest_buf, dest_size);
101 } 101 }
102 if (decoder == "LZWDecode" || decoder == "LZW") { 102 if (decoder == "LZWDecode" || decoder == "LZW") {
103 return FPDFAPI_FlateOrLZWDecode(TRUE, src_buf, limit, pParam, 0, dest_buf, 103 return FPDFAPI_FlateOrLZWDecode(TRUE, src_buf, limit, pParam, 0, dest_buf,
104 dest_size); 104 dest_size);
105 } 105 }
106 if (decoder == "DCTDecode" || decoder == "DCT") { 106 if (decoder == "DCTDecode" || decoder == "DCT") {
107 CCodec_ScanlineDecoder* pDecoder = 107 CCodec_ScanlineDecoder* pDecoder =
108 CPDF_ModuleMgr::Get()->GetJpegModule()->CreateDecoder( 108 CPDF_ModuleMgr::Get()->GetJpegModule()->CreateDecoder(
109 src_buf, limit, width, height, 0, 109 src_buf, limit, width, height, 0,
110 pParam ? pParam->GetIntegerFor("ColorTransform", 1) : 1); 110 !pParam || pParam->GetIntegerFor("ColorTransform", 1));
111 return DecodeAllScanlines(pDecoder, dest_buf, dest_size); 111 return DecodeAllScanlines(pDecoder, dest_buf, dest_size);
112 } 112 }
113 if (decoder == "RunLengthDecode" || decoder == "RL") { 113 if (decoder == "RunLengthDecode" || decoder == "RL") {
114 return RunLengthDecode(src_buf, limit, dest_buf, dest_size); 114 return RunLengthDecode(src_buf, limit, dest_buf, dest_size);
115 } 115 }
116 dest_size = 0; 116 dest_size = 0;
117 dest_buf = 0; 117 dest_buf = 0;
118 return (uint32_t)-1; 118 return (uint32_t)-1;
119 } 119 }
120 120
(...skipping 716 matching lines...) Expand 10 before | Expand all | Expand 10 after
837 } 837 }
838 m_Status = Done; 838 m_Status = Done;
839 return; 839 return;
840 } 840 }
841 steps++; 841 steps++;
842 if (pPause && pPause->NeedToPauseNow()) { 842 if (pPause && pPause->NeedToPauseNow()) {
843 break; 843 break;
844 } 844 }
845 } 845 }
846 } 846 }
OLDNEW
« no previous file with comments | « no previous file | core/fpdfapi/parser/cpdf_security_handler.h » ('j') | core/fpdfapi/render/fpdf_render_loadimage.cpp » ('J')

Powered by Google App Engine
This is Rietveld 408576698