Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code | Sign in
(2012)

Issue 6330061: code review 6330061: encoding/xml: Allow comments in DOCTYPE (Closed)

Can't Edit
Can't Publish+Mail
Start Review
Created:
11 years, 10 months ago by shawnps
Modified:
10 years, 3 months ago
Reviewers:
rsc
CC:
rsc, niemeyer, golang-dev
Visibility:
Public.

Description

encoding/xml: Allow comments in DOCTYPE I mentioned on the golang-nuts mailing list that comments in directives like DOCTYPE can break XML parsing: https://groups.google.com/forum/?fromgroups#!topic/golang-nuts/DgThEhl8fv0 That thread also explains how to recreate the problem I encountered. This patch hopefully fixes that problem, as well as adds a test for making sure directives with comments in them get parsed correctly.

Patch Set 1 #

Patch Set 2 : diff -r 7abccc974354 https://code.google.com/p/go #

Patch Set 3 : diff -r d8bd45866999 https://code.google.com/p/go #

Patch Set 4 : diff -r 63d9b9b595c5 https://code.google.com/p/go #

Total comments: 8

Patch Set 5 : diff -r 422b4a8160bc https://code.google.com/p/go #

Patch Set 6 : diff -r 422b4a8160bc https://code.google.com/p/go #

Patch Set 7 : diff -r 422b4a8160bc https://code.google.com/p/go #

Unified diffs Side-by-side diffs Delta from patch set Stats (+63 lines, -1 line) Patch
M src/pkg/encoding/xml/xml.go View 1 2 3 4 5 6 2 chunks +30 lines, -1 line 0 comments Download
M src/pkg/encoding/xml/xml_test.go View 1 2 3 4 1 chunk +33 lines, -0 lines 0 comments Download

Messages

Total messages: 34
shawnps
Hello golang-dev@googlegroups.com, I'd like you to review this change to https://code.google.com/p/go
11 years, 10 months ago (2012-06-27 06:12:12 UTC) #1
adg
I'll leave reviewing this change to someone more familiar with the xml package, but for ...
11 years, 10 months ago (2012-07-02 18:52:08 UTC) #2
shawnps
On 2012/07/02 18:52:08, adg wrote: > I'll leave reviewing this change to someone more familiar ...
11 years, 9 months ago (2012-07-02 19:54:23 UTC) #3
nigeltao
On 3 July 2012 04:52, <adg@golang.org> wrote: > I'll leave reviewing this change to someone ...
11 years, 9 months ago (2012-07-02 23:00:01 UTC) #4
shawnps
On 2012/07/02 23:00:01, nigeltao wrote: > On 3 July 2012 04:52, <mailto:adg@golang.org> wrote: > > ...
11 years, 9 months ago (2012-07-02 23:14:52 UTC) #5
adg
If Gustavo wants to take a look, that's also fine. Andrew On 2 July 2012 ...
11 years, 9 months ago (2012-07-03 00:36:03 UTC) #6
shawnps
Hello golang-dev@googlegroups.com, adg@golang.org, nigeltao@golang.org (cc: golang-dev@googlegroups.com), Please take another look.
11 years, 9 months ago (2012-07-11 07:15:21 UTC) #7
shawnps
On 2012/07/03 00:36:03, adg wrote: > If Gustavo wants to take a look, that's also ...
11 years, 9 months ago (2012-07-11 07:16:01 UTC) #8
shawnps
On 2012/07/11 07:16:01, shawnps wrote: > On 2012/07/03 00:36:03, adg wrote: > > If Gustavo ...
11 years, 9 months ago (2012-07-11 07:24:26 UTC) #9
nigeltao
On 2012/07/11 07:15:21, shawnps wrote: > Hello mailto:golang-dev@googlegroups.com, mailto:adg@golang.org, mailto:nigeltao@golang.org (cc: > mailto:golang-dev@googlegroups.com), > > ...
11 years, 9 months ago (2012-07-11 08:50:57 UTC) #10
rsc
http://codereview.appspot.com/6330061/diff/11002/src/pkg/encoding/xml/xml.go File src/pkg/encoding/xml/xml.go (left): http://codereview.appspot.com/6330061/diff/11002/src/pkg/encoding/xml/xml.go#oldcode853 src/pkg/encoding/xml/xml.go:853: var semicolon bool This does not appear to have ...
11 years, 9 months ago (2012-07-29 22:31:41 UTC) #11
shawnps
http://codereview.appspot.com/6330061/diff/11002/src/pkg/encoding/xml/xml.go File src/pkg/encoding/xml/xml.go (left): http://codereview.appspot.com/6330061/diff/11002/src/pkg/encoding/xml/xml.go#oldcode853 src/pkg/encoding/xml/xml.go:853: var semicolon bool On 2012/07/29 22:31:41, rsc wrote: > ...
11 years, 9 months ago (2012-07-30 01:30:29 UTC) #12
shawnps
On 2012/07/30 01:30:29, shawnps wrote: > http://codereview.appspot.com/6330061/diff/11002/src/pkg/encoding/xml/xml.go > File src/pkg/encoding/xml/xml.go (left): > > http://codereview.appspot.com/6330061/diff/11002/src/pkg/encoding/xml/xml.go#oldcode853 > ...
11 years, 9 months ago (2012-07-30 01:32:18 UTC) #13
rsc
> This is probably due to a misunderstanding I'm experiencing regarding > Mercurial. > > ...
11 years, 9 months ago (2012-07-30 01:32:29 UTC) #14
rsc
> Sorry, what I meant to say was, is it reasonable for me to do ...
11 years, 9 months ago (2012-07-30 01:33:37 UTC) #15
shawnps
Here is the output of 'hg sum' after copying my modified xml.go and xml_test.go back ...
11 years, 9 months ago (2012-07-30 01:37:10 UTC) #16
shawnps
Ah, should I have done "hg update weekly" instead of "hg update release"? On Sun, ...
11 years, 9 months ago (2012-07-30 01:38:45 UTC) #17
rsc
Please copy your xml.go changes somewhere, and then 'hg update default' to switch to the ...
11 years, 9 months ago (2012-07-30 01:38:58 UTC) #18
shawnps
I see them now, yes. Should I delete the old patch sets, reapply my changes, ...
11 years, 9 months ago (2012-07-30 01:45:02 UTC) #19
rsc
On Sun, Jul 29, 2012 at 9:45 PM, Shawn Smith <shawn.p.smith@gmail.com> wrote: > I see ...
11 years, 9 months ago (2012-07-30 02:32:35 UTC) #20
shawnps
http://codereview.appspot.com/6330061/diff/11002/src/pkg/encoding/xml/xml.go File src/pkg/encoding/xml/xml.go (right): http://codereview.appspot.com/6330061/diff/11002/src/pkg/encoding/xml/xml.go#newcode587 src/pkg/encoding/xml/xml.go:587: d.buf.WriteByte(b) On 2012/07/29 22:31:41, rsc wrote: > HandleB: > ...
11 years, 9 months ago (2012-07-30 04:35:58 UTC) #21
shawnps
http://codereview.appspot.com/6330061/diff/11002/src/pkg/encoding/xml/xml.go File src/pkg/encoding/xml/xml.go (right): http://codereview.appspot.com/6330061/diff/11002/src/pkg/encoding/xml/xml.go#newcode587 src/pkg/encoding/xml/xml.go:587: d.buf.WriteByte(b) On 2012/07/29 22:31:41, rsc wrote: > HandleB: > ...
11 years, 9 months ago (2012-07-31 04:40:07 UTC) #22
rsc
On 2012/07/31 04:40:07, shawnps wrote: > http://codereview.appspot.com/6330061/diff/11002/src/pkg/encoding/xml/xml.go > File src/pkg/encoding/xml/xml.go (right): > > http://codereview.appspot.com/6330061/diff/11002/src/pkg/encoding/xml/xml.go#newcode587 > ...
11 years, 8 months ago (2012-08-03 19:07:08 UTC) #23
shawnps
Hello rsc@golang.org, n13m3y3r@gmail.com (cc: golang-dev@googlegroups.com), Please take another look.
11 years, 8 months ago (2012-08-04 08:12:01 UTC) #24
shawnps
On 2012/08/04 08:12:01, shawnps wrote: > Hello mailto:rsc@golang.org, mailto:n13m3y3r@gmail.com (cc: mailto:golang-dev@googlegroups.com), > > Please take ...
11 years, 8 months ago (2012-08-04 08:16:01 UTC) #25
shawnps
Hello rsc@golang.org, n13m3y3r@gmail.com (cc: golang-dev@googlegroups.com), Please take another look.
11 years, 8 months ago (2012-08-04 08:20:20 UTC) #26
shawnps
On 2012/08/04 08:20:20, shawnps wrote: > Hello mailto:rsc@golang.org, mailto:n13m3y3r@gmail.com (cc: mailto:golang-dev@googlegroups.com), > > Please take ...
11 years, 8 months ago (2012-08-04 08:21:06 UTC) #27
rsc
When you ran hg revert xml.go it removed it from this CL. Now that it's ...
11 years, 8 months ago (2012-08-05 22:28:03 UTC) #28
shawnps
Hello rsc@golang.org, n13m3y3r@gmail.com (cc: golang-dev@googlegroups.com), Please take another look.
11 years, 8 months ago (2012-08-06 02:33:02 UTC) #29
rsc
LGTM
11 years, 8 months ago (2012-08-30 14:36:34 UTC) #30
rsc
Sorry for the delay here. This looks good but please complete a CLA as described ...
11 years, 8 months ago (2012-08-30 14:39:34 UTC) #31
shawnps
On 2012/08/30 14:39:34, rsc wrote: > Sorry for the delay here. This looks good but ...
11 years, 8 months ago (2012-08-30 17:55:47 UTC) #32
rsc
LGTM Will submit shortly.
11 years, 7 months ago (2012-08-31 19:53:27 UTC) #33
rsc
11 years, 7 months ago (2012-08-31 22:09:37 UTC) #34
*** Submitted as http://code.google.com/p/go/source/detail?r=875f1254c382 ***

encoding/xml: parse comments in DOCTYPE

R=rsc, n13m3y3r
CC=golang-dev
http://codereview.appspot.com/6330061

Committer: Russ Cox <rsc@golang.org>
Sign in to reply to this message.

Powered by Google App Engine
RSS Feeds Recent Issues | This issue
This is Rietveld f62528b