mirror of
https://github.com/netsurf-browser/netsurf
synced 2025-02-17 15:04:18 +03:00
Protect <pre> fix in cases where c->style is NULL
svn path=/trunk/netsurf/; revision=3673
This commit is contained in:
parent
23781fb862
commit
13b91169fd
@ -893,9 +893,11 @@ bool layout_inline_container(struct box *inline_container, int width,
|
||||
|
||||
has_text_children = false;
|
||||
for (c = inline_container->children; c; c = c->next) {
|
||||
bool is_pre = (c->style->white_space == CSS_WHITE_SPACE_PRE ||
|
||||
c->style->white_space == CSS_WHITE_SPACE_PRE_LINE ||
|
||||
c->style->white_space == CSS_WHITE_SPACE_PRE_WRAP);
|
||||
bool is_pre = false;
|
||||
if (c->style)
|
||||
is_pre = (c->style->white_space == CSS_WHITE_SPACE_PRE ||
|
||||
c->style->white_space == CSS_WHITE_SPACE_PRE_LINE ||
|
||||
c->style->white_space == CSS_WHITE_SPACE_PRE_WRAP);
|
||||
if ((!c->object && c->text && (c->length || is_pre)) || c->type == BOX_BR)
|
||||
has_text_children = true;
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user