Make sure an empty host matches the internal representation "nullOrigin" in WebCore...
authorwilander@apple.com <wilander@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 8 Mar 2019 00:23:51 +0000 (00:23 +0000)
committerwilander@apple.com <wilander@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 8 Mar 2019 00:23:51 +0000 (00:23 +0000)
commitf662e3545d548532aa4d2a1942debd1124ac0df4
treee482f2d4977e4ba265b6702a49b7f7c91ffd29ba
parentb1de4f41d09d73a14f3352b93036ad50b338db1b
Make sure an empty host matches the internal representation "nullOrigin" in WebCore::RegistrableDomain::matches()
https://bugs.webkit.org/show_bug.cgi?id=195435

Reviewed by Brent Fulgham.

No new tests. Tests are currently failing and will pass again with
this patch.

WebCore::RegistrableDomain::matches() is a quick way to compare a
RegistrableDomain with a URL. Since RegistrableDomain represents the
empty host as "nullOrigin," a URL with an empty host needs to match
that representation in WebCore::RegistrableDomain::matches().
Failure to do so caused debug assertions in fast/ layout tests after
https://trac.webkit.org/changeset/242603/webkit.

* platform/RegistrableDomain.h:
(WebCore::RegistrableDomain::matches const):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@242620 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Source/WebCore/ChangeLog
Source/WebCore/platform/RegistrableDomain.h