mirror of
https://github.com/RGBCube/serenity
synced 2025-07-25 16:17:45 +00:00
LibWeb: Fix two uninitialized variables in FormattingContext
This commit is contained in:
parent
a2348ebcc0
commit
0f2d5f91dc
1 changed files with 2 additions and 2 deletions
|
@ -1058,7 +1058,7 @@ float FormattingContext::calculate_min_content_height(Layout::Box const& box, Av
|
|||
return *box.intrinsic_height();
|
||||
|
||||
bool is_cacheable = available_width.is_definite() || available_width.is_intrinsic_sizing_constraint();
|
||||
Optional<float>* cache_slot;
|
||||
Optional<float>* cache_slot = nullptr;
|
||||
if (is_cacheable) {
|
||||
auto& root_state = m_state.m_root;
|
||||
auto& cache = *root_state.intrinsic_sizes.ensure(&box, [] { return adopt_own(*new LayoutState::IntrinsicSizes); });
|
||||
|
@ -1103,7 +1103,7 @@ float FormattingContext::calculate_max_content_height(Layout::Box const& box, Av
|
|||
return *box.intrinsic_height();
|
||||
|
||||
bool is_cacheable = available_width.is_definite() || available_width.is_intrinsic_sizing_constraint();
|
||||
Optional<float>* cache_slot;
|
||||
Optional<float>* cache_slot = nullptr;
|
||||
if (is_cacheable) {
|
||||
auto& root_state = m_state.m_root;
|
||||
auto& cache = *root_state.intrinsic_sizes.ensure(&box, [] { return adopt_own(*new LayoutState::IntrinsicSizes); });
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue