Index: Source/core/rendering/RenderGrid.cpp |
diff --git a/Source/core/rendering/RenderGrid.cpp b/Source/core/rendering/RenderGrid.cpp |
index 9d0d58990de04c5fe7aeb8b1dee48edbb24739b6..0a753c1dea0de20ba1bf1794f2a7d9be945532bc 100644 |
--- a/Source/core/rendering/RenderGrid.cpp |
+++ b/Source/core/rendering/RenderGrid.cpp |
@@ -595,6 +595,9 @@ void RenderGrid::resolveContentBasedTrackSizingFunctionsForItems(TrackSizingDire |
tracks.append(&track); |
} |
+ if (tracks.isEmpty()) |
+ return; |
+ |
LayoutUnit additionalBreadthSpace = (this->*sizingFunction)(gridItem, direction, columnTracks); |
for (size_t trackIndexForSpace = initialTrackIndex; trackIndexForSpace <= finalTrackIndex; ++trackIndexForSpace) { |
GridTrack& track = (direction == ForColumns) ? columnTracks[trackIndexForSpace] : rowTracks[trackIndexForSpace]; |