Revert "Part 1. Move IsLocalRefURL to nsContentUtils to reuse this function. (port-rewrite)"

This reverts commit 19f010c62022e269f99066a8d90e3522fe31adaf.
This commit is contained in:
wolfbeast 2018-09-04 17:59:40 +02:00 committed by Roy Tam
commit 5cc1408b3d
3 changed files with 18 additions and 25 deletions

View file

@ -9787,19 +9787,3 @@ nsContentUtils::AttemptLargeAllocationLoad(nsIHttpChannel* aChannel)
return reloadSucceeded;
}
/* static */ bool
nsContentUtils::IsLocalRefURL(const nsString& aString)
{
// Find the first non-"C0 controls + space" character.
const char16_t* current = aString.get();
for (; *current != '\0'; current++) {
if (*current > 0x20) {
// if the first non-"C0 controls + space" character is '#', this is a
// local-ref URL.
return *current == '#';
}
}
return false;
}