Skip to content
Browse files
Null check split node parent in outdentParagraph

Patch by Rob Buis <> on 2022-05-23
Reviewed by Wenson Hsieh.

The split node parent needs an extra null check to access its parent
before safely calling hasEditableStyle.

* Source/WebCore/editing/IndentOutdentCommand.cpp:

Canonical link:
git-svn-id: 268f45cc-cd09-0410-ab3c-d52691b4dbfc
  • Loading branch information
rwlbuis authored and webkit-commit-queue committed May 23, 2022
1 parent e00d2ca commit 9c4deed04fd3a307da74b625131ac728d81ea4b1
Showing 1 changed file with 1 addition and 0 deletions.
@@ -164,6 +164,7 @@ void IndentOutdentCommand::outdentParagraph()
if (ContainerNode* splitPointParent = splitPoint->parentNode()) {
if (splitPointParent->hasTagName(blockquoteTag)
&& !splitPoint->hasTagName(blockquoteTag)
&& splitPointParent->parentNode()
&& splitPointParent->parentNode()->hasEditableStyle()) // We can't outdent if there is no place to go!
splitElement(downcast<Element>(*splitPointParent), *splitPoint);

0 comments on commit 9c4deed

Please sign in to comment.