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

Issue 1774913003: (Re-commit) Fix SVGDocument return title that is not a child of the root element (Closed)

Created:
4 years, 9 months ago by hyunjunekim2
Modified:
4 years, 9 months ago
Reviewers:
pdr., fs
CC:
blink-reviews, blink-reviews-dom_chromium.org, blink-reviews-w3ctests_chromium.org, chromium-reviews, dglazkov+blink, krit, eae+blinkwatch, f(malita), gyuyoung2, kouhei+svg_chromium.org, pdr+svgwatchlist_chromium.org, rwlbuis, Stephen Chennney, sof, tfarina
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Fix SVGDocument return title that is not a child of the root element The title element should be a child of the root element. But currently return invalid title that is not a child of the root element. Because on getting, if the root element is an svg element in the SVG namespace, then let value ba a concatenation of the data of all the child Text nodes of the first title element in the SVG namespace that is a child of the root element.[1] And on setting, let element be the first title element in the SVG namespace that is a child of the root element, if any. If there isn't one, create a title element in the SVG namespace, insert it as the first child of the root element, and let element be that element.[1] About a patch reverted[2][3], didn't consider inner svg document in <html> or etc but is not <svg>. If be inner svg document and insert <title> element that is not svg namespace two times, occurred to crash. Because call the member function of instance(m_titleElement) that is null. And added crash case that is set-title-element-on-inner-svg-document.html. [1] https://html.spec.whatwg.org/multipage/dom.html#document.title [2] https://codereview.chromium.org/1771703003/ [3] https://codereview.chromium.org/1752713002/ BUG=543061, 592323 Committed: https://crrev.com/962d172872d7097c7074c6597fd52732882a1d9f Cr-Commit-Position: refs/heads/master@{#380634}

Patch Set 1 #

Patch Set 2 : #

Patch Set 3 : #

Patch Set 4 : #

Patch Set 5 : #

Total comments: 6

Patch Set 6 : #

Patch Set 7 : #

Patch Set 8 : #

Total comments: 3

Patch Set 9 : #

Patch Set 10 : #

Total comments: 5

Patch Set 11 : #

Patch Set 12 : #

Patch Set 13 : #

Total comments: 2

Patch Set 14 : #

Messages

Total messages: 64 (40 generated)
hyunjunekim2
fs, pdr Hi, Could you check this patch and give me advice? Thank you.
4 years, 9 months ago (2016-03-08 16:20:36 UTC) #17
hyunjunekim2
On 2016/03/08 16:20:36, hyunjunekim2 wrote: > fs, pdr > Hi, Could you check this patch ...
4 years, 9 months ago (2016-03-08 16:21:55 UTC) #18
fs
On 2016/03/08 at 16:21:55, hyunjune.kim wrote: > On 2016/03/08 16:20:36, hyunjunekim2 wrote: > > fs, ...
4 years, 9 months ago (2016-03-08 17:05:26 UTC) #19
fs
On 2016/03/08 at 17:05:26, fs wrote: > On 2016/03/08 at 16:21:55, hyunjune.kim wrote: > > ...
4 years, 9 months ago (2016-03-08 17:06:24 UTC) #20
fs
On 2016/03/08 at 17:05:26, fs wrote: > On 2016/03/08 at 16:21:55, hyunjune.kim wrote: > > ...
4 years, 9 months ago (2016-03-08 17:19:03 UTC) #21
hyunjunekim2
fs, Could you check this patch? > So an additional null-check upon the original fix ...
4 years, 9 months ago (2016-03-09 15:54:46 UTC) #39
fs
On 2016/03/09 at 15:54:46, hyunjune.kim wrote: ... > For cover this case, > > // ...
4 years, 9 months ago (2016-03-09 16:06:48 UTC) #40
hyunjunekim2
Add test(set-title-html-namespace-on-SVG.html).
4 years, 9 months ago (2016-03-09 16:07:24 UTC) #41
hyunjunekim2
> Yes, that's probably a reasonable interpretation of the specification. I'd > suggest that you ...
4 years, 9 months ago (2016-03-09 16:09:15 UTC) #42
hyunjunekim2
fs, I rewrote codes on the document. Could you check PS15(code, tests)? Thank you.
4 years, 9 months ago (2016-03-10 14:23:55 UTC) #43
fs
https://codereview.chromium.org/1774913003/diff/180001/third_party/WebKit/Source/core/dom/Document.cpp File third_party/WebKit/Source/core/dom/Document.cpp (right): https://codereview.chromium.org/1774913003/diff/180001/third_party/WebKit/Source/core/dom/Document.cpp#newcode1336 third_party/WebKit/Source/core/dom/Document.cpp:1336: // If the root element is an svg element ...
4 years, 9 months ago (2016-03-10 14:41:48 UTC) #46
hyunjunekim2
fs, Could you give me advice? Also I will check other browsers. Thank you. https://codereview.chromium.org/1774913003/diff/140001/third_party/WebKit/LayoutTests/svg/dom/set-title-element-on-inner-svg-document.html ...
4 years, 9 months ago (2016-03-10 15:00:44 UTC) #47
fs
On 2016/03/10 at 15:00:44, hyunjune.kim wrote: ... > https://codereview.chromium.org/1774913003/diff/180001/third_party/WebKit/Source/core/dom/Document.cpp#newcode1336 > third_party/WebKit/Source/core/dom/Document.cpp:1336: // If the root ...
4 years, 9 months ago (2016-03-10 15:09:37 UTC) #48
hyunjunekim2
On 2016/03/10 15:09:37, fs wrote: > On 2016/03/10 at 15:00:44, hyunjune.kim wrote: > ... > ...
4 years, 9 months ago (2016-03-10 16:22:40 UTC) #49
fs
https://codereview.chromium.org/1774913003/diff/240001/third_party/WebKit/Source/core/dom/Document.cpp File third_party/WebKit/Source/core/dom/Document.cpp (right): https://codereview.chromium.org/1774913003/diff/240001/third_party/WebKit/Source/core/dom/Document.cpp#newcode1323 third_party/WebKit/Source/core/dom/Document.cpp:1323: if (m_titleElement && documentElement() == m_titleElement->parentNode()) { Traversal<SVGTitleElement>::firstChild guarantees ...
4 years, 9 months ago (2016-03-10 16:47:01 UTC) #50
hyunjunekim2
fs, Could you check PS14? Thank you. https://codereview.chromium.org/1774913003/diff/240001/third_party/WebKit/Source/core/dom/Document.cpp File third_party/WebKit/Source/core/dom/Document.cpp (right): https://codereview.chromium.org/1774913003/diff/240001/third_party/WebKit/Source/core/dom/Document.cpp#newcode1323 third_party/WebKit/Source/core/dom/Document.cpp:1323: if (m_titleElement ...
4 years, 9 months ago (2016-03-10 17:04:39 UTC) #51
fs
lgtm
4 years, 9 months ago (2016-03-10 17:09:41 UTC) #52
hyunjunekim2
On 2016/03/10 17:09:41, fs wrote: > lgtm > Yes, that's probably a reasonable interpretation of ...
4 years, 9 months ago (2016-03-11 08:56:42 UTC) #53
fs
On 2016/03/11 at 08:56:42, hyunjune.kim wrote: > On 2016/03/10 17:09:41, fs wrote: > > lgtm ...
4 years, 9 months ago (2016-03-11 08:58:22 UTC) #54
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1774913003/260001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1774913003/260001
4 years, 9 months ago (2016-03-11 10:24:52 UTC) #56
commit-bot: I haz the power
Try jobs failed on following builders: linux_chromium_rel_ng on tryserver.chromium.linux (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.linux/builders/linux_chromium_rel_ng/builds/195355)
4 years, 9 months ago (2016-03-11 12:39:41 UTC) #58
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1774913003/260001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1774913003/260001
4 years, 9 months ago (2016-03-11 12:58:56 UTC) #60
commit-bot: I haz the power
Committed patchset #14 (id:260001)
4 years, 9 months ago (2016-03-11 14:58:32 UTC) #62
commit-bot: I haz the power
4 years, 9 months ago (2016-03-11 15:00:15 UTC) #64
Message was sent while issue was closed.
Patchset 14 (id:??) landed as
https://crrev.com/962d172872d7097c7074c6597fd52732882a1d9f
Cr-Commit-Position: refs/heads/master@{#380634}

Powered by Google App Engine
This is Rietveld 408576698