Changeset 160525 in webkit


Ignore:
Timestamp:
Dec 12, 2013 7:50:46 PM (10 years ago)
Author:
benjamin@webkit.org
Message:

Fix a silly mistake of r160467
https://bugs.webkit.org/show_bug.cgi?id=125657

Patch by Benjamin Poulain <bpoulain@apple.com> on 2013-12-12
Reviewed by Alexey Proskuryakov.

Fix a typo. The validity check was missing the logical not.

  • platform/network/cf/ResourceHandleCFURLConnectionDelegateWithOperationQueue.cpp:

(WebCore::ResourceHandleCFURLConnectionDelegateWithOperationQueue::willSendRequest):
(WebCore::ResourceHandleCFURLConnectionDelegateWithOperationQueue::didReceiveResponse):
(WebCore::ResourceHandleCFURLConnectionDelegateWithOperationQueue::didReceiveData):
(WebCore::ResourceHandleCFURLConnectionDelegateWithOperationQueue::didFinishLoading):
(WebCore::ResourceHandleCFURLConnectionDelegateWithOperationQueue::didFail):
(WebCore::ResourceHandleCFURLConnectionDelegateWithOperationQueue::willCacheResponse):
(WebCore::ResourceHandleCFURLConnectionDelegateWithOperationQueue::didReceiveChallenge):
(WebCore::ResourceHandleCFURLConnectionDelegateWithOperationQueue::didSendBodyData):
(WebCore::ResourceHandleCFURLConnectionDelegateWithOperationQueue::shouldUseCredentialStorage):
(WebCore::ResourceHandleCFURLConnectionDelegateWithOperationQueue::canRespondToProtectionSpace):
(WebCore::ResourceHandleCFURLConnectionDelegateWithOperationQueue::didReceiveDataArray):

Location:
trunk/Source/WebCore
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/WebCore/ChangeLog

    r160520 r160525  
     12013-12-12  Benjamin Poulain  <bpoulain@apple.com>
     2
     3        Fix a silly mistake of r160467
     4        https://bugs.webkit.org/show_bug.cgi?id=125657
     5
     6        Reviewed by Alexey Proskuryakov.
     7
     8        Fix a typo. The validity check was missing the logical not.
     9
     10        * platform/network/cf/ResourceHandleCFURLConnectionDelegateWithOperationQueue.cpp:
     11        (WebCore::ResourceHandleCFURLConnectionDelegateWithOperationQueue::willSendRequest):
     12        (WebCore::ResourceHandleCFURLConnectionDelegateWithOperationQueue::didReceiveResponse):
     13        (WebCore::ResourceHandleCFURLConnectionDelegateWithOperationQueue::didReceiveData):
     14        (WebCore::ResourceHandleCFURLConnectionDelegateWithOperationQueue::didFinishLoading):
     15        (WebCore::ResourceHandleCFURLConnectionDelegateWithOperationQueue::didFail):
     16        (WebCore::ResourceHandleCFURLConnectionDelegateWithOperationQueue::willCacheResponse):
     17        (WebCore::ResourceHandleCFURLConnectionDelegateWithOperationQueue::didReceiveChallenge):
     18        (WebCore::ResourceHandleCFURLConnectionDelegateWithOperationQueue::didSendBodyData):
     19        (WebCore::ResourceHandleCFURLConnectionDelegateWithOperationQueue::shouldUseCredentialStorage):
     20        (WebCore::ResourceHandleCFURLConnectionDelegateWithOperationQueue::canRespondToProtectionSpace):
     21        (WebCore::ResourceHandleCFURLConnectionDelegateWithOperationQueue::didReceiveDataArray):
     22
    1232013-12-12  Tim Horton  <timothy_horton@apple.com>
    224
  • trunk/Source/WebCore/platform/network/cf/ResourceHandleCFURLConnectionDelegateWithOperationQueue.cpp

    r160467 r160525  
    7777
    7878    dispatch_async(dispatch_get_main_queue(), ^{
    79         if (protector->hasHandle()) {
     79        if (!protector->hasHandle()) {
    8080            continueWillSendRequest(nullptr);
    8181            return;
     
    104104
    105105    dispatch_async(dispatch_get_main_queue(), ^{
    106         if (protector->hasHandle()) {
     106        if (!protector->hasHandle()) {
    107107            continueDidReceiveResponse();
    108108            return;
     
    134134
    135135    dispatch_async(dispatch_get_main_queue(), ^{
    136         if (!protector->hasHandle()) {
     136        if (protector->hasHandle()) {
    137137            LOG(Network, "CFNet - ResourceHandleCFURLConnectionDelegateWithOperationQueue::didReceiveData(handle=%p) (%s)", m_handle, m_handle->firstRequest().url().string().utf8().data());
    138138
     
    148148    RefPtr<ResourceHandleCFURLConnectionDelegateWithOperationQueue> protector(this);
    149149    dispatch_async(dispatch_get_main_queue(), ^{
    150         if (protector->hasHandle())
     150        if (!protector->hasHandle())
    151151            return;
    152152
     
    162162    CFRetain(error);
    163163    dispatch_async(dispatch_get_main_queue(), ^{
    164         if (!protector->hasHandle()) {
     164        if (protector->hasHandle()) {
    165165            LOG(Network, "CFNet - ResourceHandleCFURLConnectionDelegateWithOperationQueue::didFail(handle=%p) (%s)", m_handle, m_handle->firstRequest().url().string().utf8().data());
    166166
     
    177177
    178178    dispatch_async(dispatch_get_main_queue(), ^{
     179        if (!protector->hasHandle()) {
     180            continueWillCacheResponse(nullptr);
     181            return;
     182        }
     183
     184        LOG(Network, "CFNet - ResourceHandleCFURLConnectionDelegateWithOperationQueue::willCacheResponse(handle=%p) (%s)", m_handle, m_handle->firstRequest().url().string().utf8().data());
     185
     186        m_handle->client()->willCacheResponseAsync(m_handle, cachedResponse);
     187    });
     188    dispatch_semaphore_wait(m_semaphore, DISPATCH_TIME_FOREVER);
     189    return m_cachedResponseResult.leakRef();
     190}
     191
     192void ResourceHandleCFURLConnectionDelegateWithOperationQueue::didReceiveChallenge(CFURLAuthChallengeRef challenge)
     193{
     194    RefPtr<ResourceHandleCFURLConnectionDelegateWithOperationQueue> protector(this);
     195    CFRetain(challenge);
     196    dispatch_async(dispatch_get_main_queue(), ^{
    179197        if (protector->hasHandle()) {
    180             continueWillCacheResponse(nullptr);
    181             return;
    182         }
    183 
    184         LOG(Network, "CFNet - ResourceHandleCFURLConnectionDelegateWithOperationQueue::willCacheResponse(handle=%p) (%s)", m_handle, m_handle->firstRequest().url().string().utf8().data());
    185 
    186         m_handle->client()->willCacheResponseAsync(m_handle, cachedResponse);
    187     });
    188     dispatch_semaphore_wait(m_semaphore, DISPATCH_TIME_FOREVER);
    189     return m_cachedResponseResult.leakRef();
    190 }
    191 
    192 void ResourceHandleCFURLConnectionDelegateWithOperationQueue::didReceiveChallenge(CFURLAuthChallengeRef challenge)
    193 {
    194     RefPtr<ResourceHandleCFURLConnectionDelegateWithOperationQueue> protector(this);
    195     CFRetain(challenge);
    196     dispatch_async(dispatch_get_main_queue(), ^{
    197         if (!protector->hasHandle()) {
    198198            LOG(Network, "CFNet - ResourceHandleCFURLConnectionDelegateWithOperationQueue::didReceiveChallenge(handle=%p) (%s)", m_handle, m_handle->firstRequest().url().string().utf8().data());
    199199
     
    209209    RefPtr<ResourceHandleCFURLConnectionDelegateWithOperationQueue> protector(this);
    210210    dispatch_async(dispatch_get_main_queue(), ^{
    211         if (protector->hasHandle())
     211        if (!protector->hasHandle())
    212212            return;
    213213
     
    223223
    224224    dispatch_async(dispatch_get_main_queue(), ^{
    225         if (protector->hasHandle()) {
     225        if (!protector->hasHandle()) {
    226226            continueShouldUseCredentialStorage(false);
    227227            return;
     
    242242
    243243    dispatch_async(dispatch_get_main_queue(), ^{
    244         if (protector->hasHandle()) {
     244        if (!protector->hasHandle()) {
    245245            continueCanAuthenticateAgainstProtectionSpace(false);
    246246            return;
     
    270270    CFRetain(dataArray);
    271271    dispatch_async(dispatch_get_main_queue(), ^{
    272         if (!protector->hasHandle()) {
     272        if (protector->hasHandle()) {
    273273            LOG(Network, "CFNet - ResourceHandleCFURLConnectionDelegateWithOperationQueue::didSendBodyData(handle=%p) (%s)", m_handle, m_handle->firstRequest().url().string().utf8().data());
    274274
Note: See TracChangeset for help on using the changeset viewer.