Bug 161805

Summary: URLParser: Handle \ in path according to spec
Product: WebKit Reporter: Alex Christensen <achristensen>
Component: New BugsAssignee: Alex Christensen <achristensen>
Status: RESOLVED FIXED    
Severity: Normal CC: commit-queue
Priority: P2    
Version: WebKit Nightly Build   
Hardware: Unspecified   
OS: Unspecified   
Attachments:
Description Flags
Patch aestes: review+

Alex Christensen
Reported 2016-09-09 10:46:34 PDT
URLParser: Handle \ in path according to spec
Attachments
Patch (5.22 KB, patch)
2016-09-09 10:48 PDT, Alex Christensen
aestes: review+
Alex Christensen
Comment 1 2016-09-09 10:48:01 PDT
WebKit Commit Bot
Comment 2 2016-09-09 10:49:32 PDT
Attachment 288414 [details] did not pass style-queue: ERROR: Tools/TestWebKitAPI/Tests/WebCore/URLParser.cpp:266: One space before end of line comments [whitespace/comments] [5] ERROR: Tools/TestWebKitAPI/Tests/WebCore/URLParser.cpp:266: Should have a space between // and comment [whitespace/comments] [4] ERROR: Tools/TestWebKitAPI/Tests/WebCore/URLParser.cpp:417: One space before end of line comments [whitespace/comments] [5] ERROR: Tools/TestWebKitAPI/Tests/WebCore/URLParser.cpp:417: Should have a space between // and comment [whitespace/comments] [4] Total errors found: 4 in 4 files If any of these errors are false positives, please file a bug against check-webkit-style.
Andy Estes
Comment 3 2016-09-09 10:53:42 PDT
Comment on attachment 288414 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=288414&action=review > Source/WebCore/platform/URLParser.cpp:618 > + { Can we just put the entire case statement in a block? > Source/WebCore/platform/URLParser.cpp:620 > + bool isSlash = *c == '/' || (m_urlIsSpecial && *c == '\\'); > + if (isSlash || *c == '?' || *c == '#') { Can you dereference c once and store it in a char?
Alex Christensen
Comment 4 2016-09-09 10:58:28 PDT
Alex Christensen
Comment 5 2016-09-09 10:59:48 PDT
(In reply to comment #3) > > Source/WebCore/platform/URLParser.cpp:620 > > + bool isSlash = *c == '/' || (m_urlIsSpecial && *c == '\\'); > > + if (isSlash || *c == '?' || *c == '#') { > > Can you dereference c once and store it in a char? I could, but I'm planning on optimizing all these if (*c==this || *c == that || ...) into tables once everything works anyways, so I'll get to it. Until then, this reads better than having another variable with a strange name.
Note You need to log in before you can comment on or make changes to this bug.