Changeset 212981 in webkit


Ignore:
Timestamp:
Feb 24, 2017 5:08:30 PM (7 years ago)
Author:
commit-queue@webkit.org
Message:

curl: Improve errors by including the domain
https://bugs.webkit.org/show_bug.cgi?id=134340

Patch by Basuke Suzuki <Basuke.Suzuki@am.sony.com> on 2017-02-24
Reviewed by Alex Christensen.

Added proper error domain to ResourceError created by
Curl problem.

  • platform/network/curl/ResourceHandleManager.cpp:

(WebCore::ResourceHandleManager::downloadTimerCallback):
(WebCore::ResourceHandleManager::dispatchSynchronousJob):

Location:
trunk/Source/WebCore
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/WebCore/ChangeLog

    r212980 r212981  
     12017-02-24  Basuke Suzuki  <Basuke.Suzuki@am.sony.com>
     2
     3        curl: Improve errors by including the domain
     4        https://bugs.webkit.org/show_bug.cgi?id=134340
     5
     6        Reviewed by Alex Christensen.
     7
     8        Added proper error domain to ResourceError created by
     9        Curl problem.
     10
     11        * platform/network/curl/ResourceHandleManager.cpp:
     12        (WebCore::ResourceHandleManager::downloadTimerCallback):
     13        (WebCore::ResourceHandleManager::dispatchSynchronousJob):
     14
    1152017-02-24  Antoine Quint  <graouts@apple.com>
    216
  • trunk/Source/WebCore/platform/network/curl/ResourceHandleManager.cpp

    r212944 r212981  
    8686const double pollTimeSeconds = 0.05;
    8787const int maxRunningJobs = 128;
     88const char* const errorDomainCurl = "CurlErrorDomain";
    8889
    8990URL getCurlEffectiveURL(CURL* handle)
     
    713714#endif
    714715            if (d->client()) {
    715                 ResourceError resourceError(String(), msg->data.result, url, String(curl_easy_strerror(msg->data.result)));
     716                ResourceError resourceError(ASCIILiteral(errorDomainCurl), msg->data.result, url, String(curl_easy_strerror(msg->data.result)));
    716717                resourceError.setSSLErrors(d->m_sslErrors);
    717718                d->client()->didFail(job, resourceError);
     
    990991
    991992    if (ret != CURLE_OK) {
    992         ResourceError error(String(handle->m_url), ret, kurl, String(curl_easy_strerror(ret)));
     993        ResourceError error(ASCIILiteral(errorDomainCurl), ret, kurl, String(curl_easy_strerror(ret)));
    993994        error.setSSLErrors(handle->m_sslErrors);
    994995        handle->client()->didFail(job, error);
Note: See TracChangeset for help on using the changeset viewer.