[Webkit-unassigned] [Bug 185105] New: ResourceHandleCFURLConnectionDelegateWithOperationQueue::didReceiveResponse() has comment that states we should avoid sniffing for HTTP 304, but we no longer do

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Fri Apr 27 20:55:43 PDT 2018


https://bugs.webkit.org/show_bug.cgi?id=185105

            Bug ID: 185105
           Summary: ResourceHandleCFURLConnectionDelegateWithOperationQueu
                    e::didReceiveResponse() has comment that states we
                    should avoid sniffing for HTTP 304, but we no longer
                    do
           Product: WebKit
           Version: WebKit Nightly Build
          Hardware: PC
                OS: Windows 10
            Status: NEW
          Severity: Normal
          Priority: P2
         Component: Platform
          Assignee: webkit-unassigned at lists.webkit.org
          Reporter: dbates at webkit.org
                CC: achristensen at apple.com

In ResourceHandleCFURLConnectionDelegateWithOperationQueue::didReceiveResponse() we have the following confusing code snippet:

[[
...
        // Avoid MIME type sniffing if the response comes back as 304 Not Modified.
        auto msg = CFURLResponseGetHTTPResponse(cfResponse.get());
        int statusCode = msg ? CFHTTPMessageGetResponseStatusCode(msg) : 0;

        if (statusCode != 304) {
            bool isMainResourceLoad = m_handle->firstRequest().requester() == ResourceRequest::Requester::MainFrame;
        }
...
]]
<https://trac.webkit.org/browser/webkit/trunk/Source/WebCore/platform/network/cf/ResourceHandleCFURLConnectionDelegateWithOperationQueue.cpp?rev=224846#L191>

This code no longer matches the comment. What should we do with this code?

-- 
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.webkit.org/pipermail/webkit-unassigned/attachments/20180428/bc784dfc/attachment.html>


More information about the webkit-unassigned mailing list