Summary: | KURLGoogle needs support for protocolInHTTPFamily | ||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
Product: | WebKit | Reporter: | David Levin <levin> | ||||||||
Component: | Platform | Assignee: | David Levin <levin> | ||||||||
Status: | RESOLVED FIXED | ||||||||||
Severity: | Normal | CC: | levin | ||||||||
Priority: | P2 | ||||||||||
Version: | 528+ (Nightly build) | ||||||||||
Hardware: | All | ||||||||||
OS: | All | ||||||||||
Attachments: |
|
Description
David Levin
2009-02-06 12:45:34 PST
Created attachment 27410 [details]
Patch for bug.
Comment on attachment 27410 [details]
Patch for bug.
A comment make it easier to understand what lowerCaseEqualsASCII is doing. Especially in the last return.
// The last char of str should be NULL if we reached the end
or similar.
It seems initProtocolInHTTPFamily should use:
m_protocolInHTTPFamiy = m_isValid
&& (m_parsed.scheme.len == 4 && lowerCaseEqualsASCII(m_utf8.data(), m_utf8.data() + 4, "http") || ...
That would be much shorter. :)
Also, we should probably fix query_encoding to match WebKIt naming conventions while we're here.
Otherwise looks fine.
Created attachment 27420 [details]
Patch for bug.
I change the fixes slightly in response to your comments and added a comment as suggested.
Also, since you suggested fixing a casingIssue, I did this throughout the file and fixed a few other style issues in the file.
Created attachment 27421 [details]
Patch for bug.
Comment on attachment 27421 [details]
Patch for bug.
r=me
Committing to http://svn.webkit.org/repository/webkit/trunk ... M WebCore/ChangeLog M WebCore/platform/KURL.h M WebCore/platform/KURLGoogle.cpp M WebCore/platform/KURLGooglePrivate.h Committed r40735 |