summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2015-01-07Transform font size to user space for valid text size comparison.chromium/2214Lei Zhang
BUG=438441 https://codereview.chromium.org/816153002 (Manual merge of commit a09d50d09259bd90c865e92026a69f5434678e71) Review URL: https://codereview.chromium.org/814303003
2014-12-18Fix a bug that occurs when an object has the same object number with the ↵Lei Zhang
root object Before this fix, the root will be released when an indirect object has the same object number with the root. However, the root object is loaded when the trailer is parsed. It shall not be updated or replaced anymore. BUG=425040 R=tsepez@chromium.org Review URL: https://codereview.chromium.org/803103002 (cherry picked from commit dba5bfd174589ad08c4231b039297b59fa2ccc3b) Review URL: https://codereview.chromium.org/792013005
2014-12-17Update openjpeg to r2920Lei Zhang
BUG=414036, 425151 R=tsepez@chromium.org Review URL: https://codereview.chromium.org/688633003 (cherry picked from commit 2b327f83ffcceca1911479c4afddafe51f0e37ba) Review URL: https://codereview.chromium.org/788983004
2014-12-15Do not do strict check of BitsPerComponent for RunLengthDecode filterLei Zhang
BUG=438421 R=tsepez@chromium.org Review URL: https://codereview.chromium.org/790363002 (cherry picked from commit 869517236c27b92b7060da7f44a0b01e252e8211) Review URL: https://codereview.chromium.org/806133002
2014-12-15Update to openjpeg r2944Lei Zhang
BUG=429139,430566,431288 R=tsepez@chromium.org Review URL: https://codereview.chromium.org/758593002 (cherry picked from commit 4643533ca3dabe945fd174caf892a3ccb6cf2fd6) Review URL: https://codereview.chromium.org/804173004
2014-12-15Lab colorspace needs to be 3 componentLei Zhang
BUG=429134 R=tsepez@chromium.org Review URL: https://codereview.chromium.org/791223002 (cherry picked from commit 381b911795bb42295e61976b0df3d7e46b780d02) Review URL: https://codereview.chromium.org/807093002
2014-12-02Fix blank page issues caused by too strict checkLei Zhang
Before this fix, PDF parser aborts the parsering process when detecting an error. For this case, PDF parser just gives up parsering when it detects that the length of image stream is incorrect. The solution to this case is to find the tag "endstream" and "endobj" to calculate the length rather than aborting the parsering process. BUG=433339 R=tsepez@chromium.org Review URL: https://codereview.chromium.org/743263002 (cherry picked from commit ef619d0562b39f30943cfdc4985a0df233d00e42) Review URL: https://codereview.chromium.org/776833002
2014-10-22update openjpeg to r2911Bo Xu
BUG=418976, 425150, 414525 R=tsepez@chromium.org Review URL: https://codereview.chromium.org/671943002
2014-10-21Change the clear order of pDocPage and pDocRenderBo Xu
pTransfer function is released in pDocRender cleanup but is still being accessed in ~CPDF_GeneralStateData in pDocPage cleanup. BUG=419320 R=tsepez@chromium.org Review URL: https://codereview.chromium.org/662063003
2014-10-21Update openjpeg to r2908chromium/2202chromium/2201chromium/2200chromium/2199chromium/2198chromium/2197Bo Xu
BUG=414089, 414310, 414606 R=tsepez@chromium.org Review URL: https://codereview.chromium.org/670813002
2014-10-21More fixes in sycc422_to_rgb and sycc420_to_rgb when image width is oddBo Xu
This patch is supplementary to issue 418881 R=tsepez@chromium.org Review URL: https://codereview.chromium.org/645793007
2014-10-21Add missing parenthesis in FXARGB_GETDIB macroBo Xu
You can get warning when using FXARGB_GETDIB() with & operation in the same statement like: FXARGB_GETDIB(src_scan) & 0xffffff in fx_dib_composite.cpp: ../../third_party/pdfium/core/src/fxge/dib/fx_dib_composite.cpp:737:205: error: '&' within '|' [-Werror,-Wbitwise-op-parentheses] Original patch from jiangj@opera.com R=thakis@chromium.org Review URL: https://codereview.chromium.org/578253002
2014-10-16Make DEPS not add an extra pdfium directory.John Abd-El-Malek
This makes gclient config and gclient sync work. BUG=423896 TBR=aneeshm@chromium.org Review URL: https://codereview.chromium.org/656353002
2014-10-16Fix standalone build on Linux and Mac.John Abd-El-Malek
BUG=423883 R=scottmg@chromium.org Review URL: https://codereview.chromium.org/663633002
2014-10-15Fix licenses in headers to pass Chromium's checklicenses tool.chromium/2196chromium/2195chromium/2194chromium/2193chromium/2192chromium/2191Tom Sepez
This is a re-landing of the changes in https://pdfium.googlesource.com/pdfium/+/6387aff which were lost during a libopenjpeg library roll. TBR=thestig@chromium.org Review URL: https://codereview.chromium.org/661463003
2014-10-14Store the address of the page data map's value for proper referencing.Bo Xu
CPDF_Pattern objects are counted and maintained in m_PatternedMap. When a CPDF_Pattern object "pattern" is deleted, it's address is marked as NULL in m_PatternMap. This patch stores the address of CPDF_Pattern's adderss in all objects that references "pattern", to ensure valid referencing after deletion. BUG=416319, 419976, 418392 R=tsepez@chromium.org Review URL: https://codereview.chromium.org/656753002
2014-10-14Don't leave dangling pointer to out-of-scope local in ↵Tom Sepez
CPDF_StreamContentParser::Parse. This is just a bit of defensive programming; I'm not sure the situation can occur in the current code, but the following code is likely to set off a red flag to anyone who reads it: CPDF_StreamParser syntax(pData, dwSize); m_pSyntax = &syntax; since the extent of the local |syntax| is far less than the pointer member |m_pSyntax|. NULL it out before syntax goes out of scope. R=jun_fang@foxitsoftware.com Review URL: https://codereview.chromium.org/652063002
2014-10-14Glyph index is out of range in cff_get_glyph_name.Jun Fang
Glyph index shall be less than number of glyphs. BUG=418585 R=tsepez@chromium.org Review URL: https://codereview.chromium.org/652363002
2014-10-13Fix off-by-one in sizing of m_EmbeddedToUnicodes.Tom Sepez
BUG=421196 R=bo_xu@foxitsoftware.com Review URL: https://codereview.chromium.org/656463006
2014-10-10Fix a bug when image width is odd in sycc422_to_rgbBo Xu
BUG=418881 R=tsepez@chromium.org Review URL: https://codereview.chromium.org/648823002
2014-10-03Enable C linkage in fpdfppo.hBo Xu
BUG=pdfium-52 R=jun_fang@foxitsoftware.com Review URL: https://codereview.chromium.org/623893003
2014-10-03check pointer overflow in t2.cBo Xu
BUG=413375 R=tsepez@chromium.org Review URL: https://codereview.chromium.org/624023003
2014-10-03Add openjpeg pre-processor OPJ_STATIC to pdfium.gypBo Xu
Openjpeg removed the definition of OPJ_STATIC in openjpeg.h. This change is merged in https://pdfium.googlesource.com/pdfium/+/d53e6fdb0a86ca1ddb12876a60f7f2d7508b5349 So need to add OPJ_STATIC to pdfium.gyp BUG=None R=tsepez@chromium.org Review URL: https://codereview.chromium.org/624043002
2014-09-30Update openjpegBo Xu
BUG=407964, 414182, 413447 R=tsepez@chromium.org Review URL: https://codereview.chromium.org/589243004
2014-09-26Use static_assert unconditionally.chromium/2190chromium/2189Peter Kasting
BUG=none TEST=none R=jam@chromium.org Review URL: https://codereview.chromium.org/605273004
2014-09-24Rename GN public variables.chromium/2188chromium/2187chromium/2186chromium/2185chromium/2184chromium/2183chromium/2182chromium/2181chromium/2180chromium/2179chromium/2178chromium/2177chromium/2176chromium/2175chromium/2174chromium/2173chromium/2172chromium/2170chromium/2169Brett Wilson
forward_dependent_configs_from => public_deps direct_dependent_configs => public_configs R=jam@chromium.org Review URL: https://codereview.chromium.org/598093002
2014-09-24Lock page in LoadFXAnnot to prevent unintended page closingBo Xu
BUG=410326 R=tsepez@chromium.org Review URL: https://codereview.chromium.org/594403003
2014-09-22Invoke V8::Initialize() explicitly during V8 setupchromium/2168chromium/2167Jochen Eisinger
BUG=none R=jam@chromium.org Review URL: https://codereview.chromium.org/581413002
2014-09-19Add FPDF_GetSecurityHandlerRevisionBo Xu
Security handler revision number is needed to interpret file permission. BUG=None R=thestig@chromium.org Review URL: https://codereview.chromium.org/589813002
2014-09-19Fix a bug when assign the generation number of indirect objectschromium/2166chromium/2165Bo Xu
BUG=408532 R=tsepez@chromium.org Review URL: https://codereview.chromium.org/524443002
2014-09-19Adjust the order of clearing resource in CPDF_DocPageData::ClearJun Fang
Images are basic resource and are referred or used by other objects in some cases. Images should be released after the objects who uses these objects. In this case, an image object is accessed in the process of CPDF_TilingPattern's destroy. Unlikely, this image has been destroyed before. BUG=414046 R=tsepez@chromium.org Review URL: https://codereview.chromium.org/582993002
2014-09-18Fix Regression: Incomplete file loading is seen for multi page pdf files.chromium/2164chromium/2163Tom Sepez
This was introduced at PDFium revision 12a9940. There was a subtle logic change for null |parray|. BUG=415438 R=jun_fang@foxitsoftware.com Review URL: https://codereview.chromium.org/579363002
2014-09-18gn: don't remove -fno-exceptions to match gypScott Graham
Not required since: https://code.google.com/p/pdfium/issues/detail?id=28 R=jam@chromium.org BUG=chromium:335824 Review URL: https://codereview.chromium.org/567393004
2014-09-16When forcing clear page data, no need to release colorspace when releasing ↵Bo Xu
pattern BUG=414661 R=tsepez@chromium.org Review URL: https://codereview.chromium.org/572853006
2014-09-15Add a boundary check before accessing the table of 'Index to Location'Jun Fang
Before this fix, only |gindex < face->num_locations| is checked. However, the pointer, p, will be moved to next location in the first FT_NEXT_ULONG or FT_NEXT_USHORT. It may cause a crashier. So a boundary check is needed before the second FT_NEXT_ULONG or FT_NEXT_USHORT. BUG=412457 R=tsepez@chromium.org Review URL: https://codereview.chromium.org/571833002
2014-09-15Check Null pointer in CPDF_Dictionary::GetUnicodeTextBo Xu
BUG=414155 R=thakis@chromium.org Review URL: https://codereview.chromium.org/574463002
2014-09-11Fix hebrew character highlight issue in a special documentBo Xu
There is an image object and text objects in this document, but the character in each text object is reversed. When rendering, the image object is shown. However, when highlighting, the text object is selected, resulting in text index issue. Moreover, the character in the document is in reading order, which is different from normal document. BUG=pdfium:43 R=jbreiden@google.com Review URL: https://codereview.chromium.org/484503002
2014-09-10Check object type for objects used in the dictory of 'Index'chromium/2162chromium/2161chromium/2160chromium/2159chromium/2158chromium/2157chromium/2156Jun Fang
BUG=387970 R=tsepez@chromium.org Review URL: https://codereview.chromium.org/551503003
2014-09-09Change the forced clear order of CPDF_DocPageData::Clear, and remove ↵Bo Xu
m_pDocument in CPDF_Color If not forced clear, the counter of CPDF_Pattern will take care the count of referenced instance. When forced clear, clear color first to make sure pattern still exists when referencing it. BUG=411154 R=tsepez@chromium.org Review URL: https://codereview.chromium.org/554913003
2014-09-09Fix uninitialized value in CPDF_ColorStateDataBo Xu
BUG=411161 R=tsepez@chromium.org Review URL: https://codereview.chromium.org/560673002
2014-09-09Revert of Fix uninitialized value in CPDF_ColorStateData (patchset #1 id:1 ↵Bo Xu
of https://codereview.chromium.org/547863002/) Reason for revert: The initialized member variable is wrong. Needs to undo this. Original issue's description: > Fix uninitialized value in CPDF_ColorStateData > > BUG=411161 > R=tsepez@chromium.org > > Committed: https://pdfium.googlesource.com/pdfium/+/a38d4c3572b566f8e64b9ca4f725cbbc581e85ab TBR=tsepez@chromium.org,jun_fang@foxitsoftware.com NOTREECHECKS=true NOTRY=true BUG=411161 Review URL: https://codereview.chromium.org/558803004
2014-09-08Fix uninitialized value in CPDF_ColorStateDataBo Xu
BUG=411161 R=tsepez@chromium.org Review URL: https://codereview.chromium.org/547863002
2014-09-08Fix un-initialized R G B valueBo Xu
BUG=411163 R=tsepez@chromium.org Review URL: https://codereview.chromium.org/551513005
2014-09-08Convert GN visibility to be a list.chromium/2155chromium/2154chromium/2152Brett Wilson
GN visibility currently allows either string or list types, but this is causing some problems for some templates. I'm going to require it to be lists, so am changing all callers before pushing the new binary. R=jam@chromium.org Review URL: https://codereview.chromium.org/555523002
2014-09-08Merge performance fix for cmsDupToneCurve from previous upstream branch.Chris Palmer
BUG= R=jun_fang@foxitsoftware.com Review URL: https://codereview.chromium.org/534363002
2014-09-08The cause of this issue is that there is an indirect object like '112 0 R' ↵Jun Fang
but no its direct object '112 0 object' in the test pdf file. Without checking the validity, it causes a null pointer when trying to get the direct object by an indirect object. BUG=390781 R=tsepez@chromium.org Review URL: https://codereview.chromium.org/553613003
2014-09-04Add v8_platform to the JS dependencies in the GN build.chromium/2151chromium/2150chromium/2149chromium/2148chromium/2147Brett Wilson
This is required for the call to v8::platform::CreateDefaultPlatform. R=jam@chromium.org Review URL: https://codereview.chromium.org/540133002
2014-09-03Allocate m_pCompData when |m_nComponents| is updated.Bo Xu
When |m_nComponents| is changed from loading stream information, previously allocated memory that depends on |m_nComponents| needes to be freed and allocated again to enforce memory size consistency. BUG=409695 R=tsepez@chromium.org Review URL: https://codereview.chromium.org/528163002
2014-09-02Check m_nComponents when using JBIG2Decodechromium/2146Bo Xu
BUG=409692 R=tsepez@chromium.org Review URL: https://codereview.chromium.org/534763002
2014-09-02Add m_pDocument in CPDF_Color and check if page date has been forced clearBo Xu
This will prevent using freed pattern object. This is a better solution than https://pdfium.googlesource.com/pdfium/+/1b9c5c4dc41956b8c5ab17b9a882adf8a2513768 and in essence revert that patch BUG=409373 R=tsepez@chromium.org Review URL: https://codereview.chromium.org/522483003