| Index: Source/core/css/SelectorChecker.cpp
|
| diff --git a/Source/core/css/SelectorChecker.cpp b/Source/core/css/SelectorChecker.cpp
|
| index d9cfdf9d55ded72b5d351ce0a58ee1c0785f4b69..c4f4d7a468ef9bc2ab151b844a694025ad8b71d6 100644
|
| --- a/Source/core/css/SelectorChecker.cpp
|
| +++ b/Source/core/css/SelectorChecker.cpp
|
| @@ -153,10 +153,8 @@ SelectorChecker::Match SelectorChecker::match(const SelectorCheckingContext& con
|
| return SelectorFailsLocally;
|
|
|
| PseudoId pseudoId = CSSSelector::pseudoId(context.selector->pseudoType());
|
| - if (pseudoId == FIRST_LETTER) {
|
| - if (Document* document = context.element->document())
|
| - document->styleSheetCollections()->setUsesFirstLetterRules(true);
|
| - }
|
| + if (pseudoId == FIRST_LETTER)
|
| + context.element->document()->styleSheetCollections()->setUsesFirstLetterRules(true);
|
| if (pseudoId != NOPSEUDO && m_mode != SharingRules)
|
| dynamicPseudo = pseudoId;
|
| }
|
| @@ -675,7 +673,7 @@ bool SelectorChecker::checkOne(const SelectorCheckingContext& context, const Sib
|
| return !element->isDisabledFormControl();
|
| break;
|
| case CSSSelector::PseudoFullPageMedia:
|
| - return element && element->document() && element->document()->isMediaDocument();
|
| + return element && element->document()->isMediaDocument();
|
| break;
|
| case CSSSelector::PseudoDefault:
|
| return element && element->isDefaultButtonForForm();
|
|
|