Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

StyleResolverState may not be constructed with a null element. #17268

Merged
merged 1 commit into from Jun 12, 2019

Conversation

chromium-wpt-export-bot
Copy link
Collaborator

@chromium-wpt-export-bot chromium-wpt-export-bot commented Jun 11, 2019

It is dereferenced in ElementContext. Even documentElement() may
sometimes be null. With this CL, StyleResolverState and ElementContext
are always associated with a non-null Element.

In the case where we used to pass a Document for ElementContext, or
documentElement() directly, we will now pass documentElement() if not
null or avoid using StyleResolverState if it is null.

Bug: 971035
Change-Id: If7f34556f68aa8b55f157b2fbad5c0a331869e28
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1645292
Reviewed-by: Fernando Serboncini <fserb@chromium.org>
Reviewed-by: Anders Hartvoll Ruud <andruud@chromium.org>
Commit-Queue: Rune Lillesveen <futhark@chromium.org>
Cr-Commit-Position: refs/heads/master@{#668127}

Copy link
Collaborator

@wpt-pr-bot wpt-pr-bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Already reviewed downstream.

@chromium-wpt-export-bot chromium-wpt-export-bot changed the title StyleResolverState may be constructed with a null element. StyleResolverState may not be constructed with a null element. Jun 11, 2019
It is dereferenced in ElementContext. Even documentElement() may
sometimes be null. With this CL, StyleResolverState and ElementContext
are always associated with a non-null Element.

In the case where we used to pass a Document for ElementContext, or
documentElement() directly, we will now pass documentElement() if not
null or avoid using StyleResolverState if it is null.

Bug: 971035
Change-Id: If7f34556f68aa8b55f157b2fbad5c0a331869e28
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1645292
Reviewed-by: Fernando Serboncini <fserb@chromium.org>
Reviewed-by: Anders Hartvoll Ruud <andruud@chromium.org>
Commit-Queue: Rune Lillesveen <futhark@chromium.org>
Cr-Commit-Position: refs/heads/master@{#668127}
@foolip foolip force-pushed the chromium-export-cl-1645292 branch from 3c5e71f to 9ffc0ed Compare June 12, 2019 10:23
@chromium-wpt-export-bot chromium-wpt-export-bot merged commit b7595b5 into master Jun 12, 2019
@chromium-wpt-export-bot chromium-wpt-export-bot deleted the chromium-export-cl-1645292 branch June 12, 2019 10:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants