diff --git a/Tests/LibWeb/Text/expected/Selection-setBaseAndExtent-without-common-root.txt b/Tests/LibWeb/Text/expected/Selection-setBaseAndExtent-without-common-root.txt new file mode 100644 index 00000000000..5db64a560d5 --- /dev/null +++ b/Tests/LibWeb/Text/expected/Selection-setBaseAndExtent-without-common-root.txt @@ -0,0 +1 @@ + PASS (Didn't crash) diff --git a/Tests/LibWeb/Text/input/Selection-setBaseAndExtent-without-common-root.html b/Tests/LibWeb/Text/input/Selection-setBaseAndExtent-without-common-root.html new file mode 100644 index 00000000000..2c47b0f7c99 --- /dev/null +++ b/Tests/LibWeb/Text/input/Selection-setBaseAndExtent-without-common-root.html @@ -0,0 +1,11 @@ +
+ + diff --git a/Userland/Libraries/LibWeb/Selection/Selection.cpp b/Userland/Libraries/LibWeb/Selection/Selection.cpp index 6ec1284454f..0fed976d158 100644 --- a/Userland/Libraries/LibWeb/Selection/Selection.cpp +++ b/Userland/Libraries/LibWeb/Selection/Selection.cpp @@ -307,7 +307,7 @@ WebIDL::ExceptionOr