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

Issue 2020863002: Guard against invalid glyph shaping results (Closed)

Created:
4 years, 6 months ago by pdr.
Modified:
4 years, 6 months ago
Reviewers:
fs, eae
CC:
ajuma+watch_chromium.org, blink-reviews, blink-reviews-platform-graphics_chromium.org, Rik, chromium-reviews, danakj+watch_chromium.org, dshwang, drott+blinkwatch_chromium.org, krit, f(malita), jbroman, Justin Novosad, pdr+graphicswatchlist_chromium.org, rwlbuis, Stephen Chennney
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Guard against invalid glyph shaping results HarfBuzz can fail to shape all glyphs and will return a shape result shorter than the text length along with debug warnings: [ERROR:HarfBuzzShaper.cpp(375)] HarfBuzz returned empty glyph buffer after shaping. [ERROR:HarfBuzzShaper.cpp(672)] Shape result extraction failed. This patch fixes an SVG crash on the U+180E Mongolian vowel separator by ensuring CachingWordShaper::individualCharacterRanges returns a vector as long as the text run length. A DCHECK and test have been added to protect against this crash in the future. BUG=613915 Committed: https://crrev.com/433ceaeabee98073e81d552dee947aa6983efd53 Cr-Commit-Position: refs/heads/master@{#396668}

Patch Set 1 #

Total comments: 8

Patch Set 2 : Address reviewer comments #

Unified diffs Side-by-side diffs Delta from patch set Stats (+23 lines, -2 lines) Patch
A third_party/WebKit/LayoutTests/svg/text/invalid-glyph-crash.html View 1 1 chunk +9 lines, -0 lines 0 comments Download
A third_party/WebKit/LayoutTests/svg/text/invalid-glyph-crash-expected.txt View 1 chunk +4 lines, -0 lines 0 comments Download
M third_party/WebKit/Source/platform/fonts/Font.cpp View 1 1 chunk +3 lines, -1 line 0 comments Download
M third_party/WebKit/Source/platform/fonts/shaping/CachingWordShaper.cpp View 1 1 chunk +7 lines, -1 line 0 comments Download

Messages

Total messages: 21 (9 generated)
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/2020863002/1 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/2020863002/1
4 years, 6 months ago (2016-05-28 03:32:24 UTC) #2
pdr.
4 years, 6 months ago (2016-05-28 04:36:17 UTC) #5
commit-bot: I haz the power
Dry run: This issue passed the CQ dry run.
4 years, 6 months ago (2016-05-28 05:12:27 UTC) #7
fs
LGTM w/ a few points to ponder. I'm find with landing this as-is and fixing ...
4 years, 6 months ago (2016-05-28 14:08:31 UTC) #8
pdr.
https://codereview.chromium.org/2020863002/diff/1/third_party/WebKit/LayoutTests/svg/text/invalid-glyph-crash.html File third_party/WebKit/LayoutTests/svg/text/invalid-glyph-crash.html (right): https://codereview.chromium.org/2020863002/diff/1/third_party/WebKit/LayoutTests/svg/text/invalid-glyph-crash.html#newcode9 third_party/WebKit/LayoutTests/svg/text/invalid-glyph-crash.html:9: document.querySelector('text').innerHTML = 'PASS᠎'; On 2016/05/28 at 14:08:31, fs wrote: ...
4 years, 6 months ago (2016-05-28 22:58:16 UTC) #9
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/2020863002/20001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/2020863002/20001
4 years, 6 months ago (2016-05-28 22:58:39 UTC) #11
commit-bot: I haz the power
Dry run: This issue passed the CQ dry run.
4 years, 6 months ago (2016-05-29 00:39:39 UTC) #13
fs
https://codereview.chromium.org/2020863002/diff/1/third_party/WebKit/Source/platform/fonts/Font.cpp File third_party/WebKit/Source/platform/fonts/Font.cpp (right): https://codereview.chromium.org/2020863002/diff/1/third_party/WebKit/Source/platform/fonts/Font.cpp#newcode771 third_party/WebKit/Source/platform/fonts/Font.cpp:771: DCHECK(ranges.size() == static_cast<unsigned>(run.length())); On 2016/05/28 at 22:58:15, pdr. wrote: ...
4 years, 6 months ago (2016-05-29 14:35:55 UTC) #14
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/2020863002/20001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/2020863002/20001
4 years, 6 months ago (2016-05-29 23:43:40 UTC) #17
commit-bot: I haz the power
Committed patchset #2 (id:20001)
4 years, 6 months ago (2016-05-30 02:39:16 UTC) #18
commit-bot: I haz the power
Patchset 2 (id:??) landed as https://crrev.com/433ceaeabee98073e81d552dee947aa6983efd53 Cr-Commit-Position: refs/heads/master@{#396668}
4 years, 6 months ago (2016-05-30 02:40:32 UTC) #20
eae
4 years, 6 months ago (2016-05-31 17:48:37 UTC) #21
Message was sent while issue was closed.
LGTM

Powered by Google App Engine
This is Rietveld 408576698