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

Issue 1842633004: Fix CData parsing in CFDE_XMLSyntaxParser. (Closed)

Created:
4 years, 8 months ago by dsinclair
Modified:
4 years, 8 months ago
Reviewers:
Tom Sepez
CC:
pdfium-reviews_googlegroups.com
Base URL:
https://pdfium.googlesource.com/pdfium.git@master
Target Ref:
refs/heads/master
Project:
pdfium
Visibility:
Public.

Description

Fix CData parsing in CFDE_XMLSyntaxParser. This CL splits the handling of CData sections out to an individual phase of the parser. This fixes the issue with the CData parser getting confused by < characters inside the data section. BUG=pdfium:90 Committed: https://pdfium.googlesource.com/pdfium/+/11ac93cfdb9f4f25eee2ba60b947f992ab40ec54

Patch Set 1 #

Total comments: 18

Patch Set 2 : #

Patch Set 3 : #

Total comments: 2

Patch Set 4 : #

Patch Set 5 : Fix windows xfa #

Unified diffs Side-by-side diffs Delta from patch set Stats (+573 lines, -46 lines) Patch
M BUILD.gn View 1 1 chunk +1 line, -0 lines 0 comments Download
M pdfium.gyp View 1 1 chunk +1 line, -0 lines 0 comments Download
M xfa/fde/xml/fde_xml_imp.h View 1 chunk +3 lines, -1 line 0 comments Download
M xfa/fde/xml/fde_xml_imp.cpp View 1 2 3 7 chunks +40 lines, -42 lines 0 comments Download
A xfa/fde/xml/fde_xml_imp_unittest.cpp View 1 2 3 4 1 chunk +522 lines, -0 lines 0 comments Download
M xfa/fgas/crt/fgas_stream.cpp View 1 2 chunks +4 lines, -2 lines 0 comments Download
M xfa/fgas/crt/fgas_system.cpp View 1 2 1 chunk +2 lines, -1 line 0 comments Download

Messages

Total messages: 16 (3 generated)
dsinclair
PTAL. This works, but it feels sketchy, not sure why.
4 years, 8 months ago (2016-03-30 03:48:29 UTC) #2
Tom Sepez
On 2016/03/30 03:48:29, dsinclair wrote: > PTAL. > > This works, but it feels sketchy, ...
4 years, 8 months ago (2016-03-30 16:45:16 UTC) #3
Tom Sepez
On 2016/03/30 16:45:16, Tom Sepez wrote: > On 2016/03/30 03:48:29, dsinclair wrote: > > PTAL. ...
4 years, 8 months ago (2016-03-30 16:45:45 UTC) #4
Tom Sepez
https://codereview.chromium.org/1842633004/diff/1/xfa/fde/xml/fde_xml_imp_unittest.cpp File xfa/fde/xml/fde_xml_imp_unittest.cpp (right): https://codereview.chromium.org/1842633004/diff/1/xfa/fde/xml/fde_xml_imp_unittest.cpp#newcode13 xfa/fde/xml/fde_xml_imp_unittest.cpp:13: " <![CDATA[\n" I'd like to see some variations on ...
4 years, 8 months ago (2016-03-30 16:55:30 UTC) #5
Tom Sepez
https://codereview.chromium.org/1842633004/diff/1/xfa/fde/xml/fde_xml_imp.cpp File xfa/fde/xml/fde_xml_imp.cpp (right): https://codereview.chromium.org/1842633004/diff/1/xfa/fde/xml/fde_xml_imp.cpp#newcode1786 xfa/fde/xml/fde_xml_imp.cpp:1786: if (ch == '-') { This is wrong, too, ...
4 years, 8 months ago (2016-03-30 17:04:41 UTC) #6
dsinclair
I've added more tests, they don't currently pass, but can you verify that the results ...
4 years, 8 months ago (2016-03-30 17:32:13 UTC) #7
dsinclair
https://codereview.chromium.org/1842633004/diff/1/xfa/fde/xml/fde_xml_imp.cpp File xfa/fde/xml/fde_xml_imp.cpp (right): https://codereview.chromium.org/1842633004/diff/1/xfa/fde/xml/fde_xml_imp.cpp#newcode1786 xfa/fde/xml/fde_xml_imp.cpp:1786: if (ch == '-') { On 2016/03/30 17:04:41, Tom ...
4 years, 8 months ago (2016-03-30 19:18:12 UTC) #8
Tom Sepez
If I wanted to be picky, there's these, which I believe are usually treated as ...
4 years, 8 months ago (2016-03-30 20:07:12 UTC) #9
Tom Sepez
Opening XML file with chrome shows that <!--> <!---> are unterminated comments, too.
4 years, 8 months ago (2016-03-30 20:35:33 UTC) #10
dsinclair
PTAL. I added the tests for the unterminated comments, and fixed the comment parsing to ...
4 years, 8 months ago (2016-03-31 13:40:37 UTC) #11
Tom Sepez
LGTM. In reading this, I'm mentally translating "FDE_XMLSYNTAXMODE_*" into FDE_XMLSYNTAXSTATE_*, and FDE_XMLSYNTAXSTATUS_* into FDE_XMLSYNTAXRESULT_* with ...
4 years, 8 months ago (2016-03-31 16:12:23 UTC) #12
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1842633004/80001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1842633004/80001
4 years, 8 months ago (2016-03-31 16:45:06 UTC) #14
commit-bot: I haz the power
4 years, 8 months ago (2016-03-31 16:45:26 UTC) #16
Message was sent while issue was closed.
Committed patchset #5 (id:80001) as
https://pdfium.googlesource.com/pdfium/+/11ac93cfdb9f4f25eee2ba60b947f992ab40...

Powered by Google App Engine
This is Rietveld 408576698