[Webkit-unassigned] [Bug 67277] REGRESSION (r94132): broke fast/loader/location-port.html on GTK

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Wed Nov 2 09:11:04 PDT 2011


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





--- Comment #15 from Martin Robinson <mrobinson at webkit.org>  2011-11-02 09:11:04 PST ---
(From update of attachment 111957)
View in context: https://bugs.webkit.org/attachment.cgi?id=111957&action=review

This is an okay work-around for now, but the real fix should be in libsoup.

> Source/WebCore/platform/network/soup/ResourceRequestSoup.cpp:97
> +    bool hasPort = m_url.hasPort();
> +    unsigned short port = m_url.port();
>      m_url = soupURIToKURL(soup_message_get_uri(soupMessage));
>  
> +    // If port is 0, SoupURI does not have an explicitly specified port.
> +    // By default the port in KURL is 0, hence hasPort is used to determine if
> +    // a port was explicitly specified.
> +    if (hasPort && !port)
> +        m_url.setPort(port);
> +

I think it would be clearer here to do:
bool shouldPortBeResetToZero = m_url.hasPort() && !m_url.port();
m_url = soupURIToKURL(soup_message_get_uri(soupMessage));

// SoupURI cannot differeniate between an explicitly specified port 0 and no port specified.
if (shouldPortBeResetToZero)
    m_url.setPort(0);

-- 
Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.



More information about the webkit-unassigned mailing list