diff options
author | Steve Block <steveblock@google.com> | 2010-02-02 14:57:50 +0000 |
---|---|---|
committer | Steve Block <steveblock@google.com> | 2010-02-04 15:06:55 +0000 |
commit | d0825bca7fe65beaee391d30da42e937db621564 (patch) | |
tree | 7461c49eb5844ffd1f35d1ba2c8b7584c1620823 /WebCore/platform/KURLGoogle.cpp | |
parent | 3db770bd97c5a59b6c7574ca80a39e5a51c1defd (diff) | |
download | external_webkit-d0825bca7fe65beaee391d30da42e937db621564.zip external_webkit-d0825bca7fe65beaee391d30da42e937db621564.tar.gz external_webkit-d0825bca7fe65beaee391d30da42e937db621564.tar.bz2 |
Merge webkit.org at r54127 : Initial merge by git
Change-Id: Ib661abb595522f50ea406f72d3a0ce17f7193c82
Diffstat (limited to 'WebCore/platform/KURLGoogle.cpp')
-rw-r--r-- | WebCore/platform/KURLGoogle.cpp | 16 |
1 files changed, 3 insertions, 13 deletions
diff --git a/WebCore/platform/KURLGoogle.cpp b/WebCore/platform/KURLGoogle.cpp index 76b5612..65ca346 100644 --- a/WebCore/platform/KURLGoogle.cpp +++ b/WebCore/platform/KURLGoogle.cpp @@ -44,6 +44,7 @@ #include "StringHash.h" #include "NotImplemented.h" #include "TextEncoding.h" +#include <wtf/HashMap.h> #include <wtf/Vector.h> #include <wtf/StdLibExtras.h> @@ -569,12 +570,13 @@ String KURL::path() const return m_url.componentString(m_url.m_parsed.path); } -void KURL::setProtocol(const String& protocol) +bool KURL::setProtocol(const String& protocol) { KURLGooglePrivate::Replacements replacements; replacements.SetScheme(CharactersOrEmpty(protocol), url_parse::Component(0, protocol.length())); m_url.replaceComponents(replacements); + return true; } void KURL::setHost(const String& host) @@ -733,18 +735,6 @@ bool protocolIsJavaScript(const String& url) return protocolIs(url, "javascript"); } -bool isValidProtocol(const String& protocol) -{ - if (!isSchemeFirstChar(protocol[0])) - return false; - unsigned protocolLength = protocol.length(); - for (unsigned i = 1; i < protocolLength; i++) { - if (!isSchemeChar(protocol[i])) - return false; - } - return true; -} - // We copied the KURL version here on Dec 4, 2009 while doing a WebKit // merge. // |