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

Issue 2758483003: [css-grid] Fix crash removing positioned grid item (Closed)

Created:
3 years, 9 months ago by Manuel Rego
Modified:
3 years, 8 months ago
Reviewers:
CC:
chromium-reviews
Target Ref:
refs/pending/branch-heads/3029
Project:
chromium
Visibility:
Public.

Description

[css-grid] Fix crash removing positioned grid item When we add or remove a positioned item we don't need to mark the grid as dirty, because positioned items do not affect the layout of the grid at all. This was causing a crash when a positioned item was removed after a layout. As after the positioned item was removed, the method LayoutGrid::layoutBlock() was not called, so when the grid was repainted we got a crash. BUG=700383 TEST=fast/css-grid-layout/grid-crash-remove-positioned-item.html Review-Url: https://codereview.chromium.org/2748983003 Cr-Commit-Position: refs/heads/master@{#457061} (cherry picked from commit eb7634d5a91a495af9495164ffb2e5f1f91f7e09)

Patch Set 1 #

Unified diffs Side-by-side diffs Delta from patch set Stats (+38 lines, -0 lines) Patch
A third_party/WebKit/LayoutTests/fast/css-grid-layout/grid-crash-remove-positioned-item.html View 1 chunk +21 lines, -0 lines 0 comments Download
A third_party/WebKit/LayoutTests/fast/css-grid-layout/grid-crash-remove-positioned-item-expected.txt View 1 chunk +5 lines, -0 lines 0 comments Download
M third_party/WebKit/Source/core/layout/LayoutGrid.cpp View 2 chunks +12 lines, -0 lines 0 comments Download

Messages

Total messages: 1 (1 generated)
Manuel Rego
3 years, 8 months ago (2017-04-03 10:04:16 UTC) #1
Description was changed from

==========
[css-grid] Fix crash removing positioned grid item

When we add or remove a positioned item we don't need to mark
the grid as dirty, because positioned items do not affect the layout
of the grid at all.

This was causing a crash when a positioned item was removed
after a layout. As after the positioned item was removed,
the method LayoutGrid::layoutBlock() was not called,
so when the grid was repainted we got a crash.

BUG=700383
TEST=fast/css-grid-layout/grid-crash-remove-positioned-item.html

Review-Url: https://codereview.chromium.org/2748983003
Cr-Commit-Position: refs/heads/master@{#457061}
(cherry picked from commit eb7634d5a91a495af9495164ffb2e5f1f91f7e09)
==========

to

==========
[css-grid] Fix crash removing positioned grid item

When we add or remove a positioned item we don't need to mark
the grid as dirty, because positioned items do not affect the layout
of the grid at all.

This was causing a crash when a positioned item was removed
after a layout. As after the positioned item was removed,
the method LayoutGrid::layoutBlock() was not called,
so when the grid was repainted we got a crash.

BUG=700383
TEST=fast/css-grid-layout/grid-crash-remove-positioned-item.html

Review-Url: https://codereview.chromium.org/2748983003
Cr-Commit-Position: refs/heads/master@{#457061}
(cherry picked from commit eb7634d5a91a495af9495164ffb2e5f1f91f7e09)
==========

Powered by Google App Engine
This is Rietveld 408576698