Changeset 160525 in webkit
- Timestamp:
- Dec 12, 2013 7:50:46 PM (10 years ago)
- Location:
- trunk/Source/WebCore
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Source/WebCore/ChangeLog
r160520 r160525 1 2013-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 1 23 2013-12-12 Tim Horton <timothy_horton@apple.com> 2 24 -
trunk/Source/WebCore/platform/network/cf/ResourceHandleCFURLConnectionDelegateWithOperationQueue.cpp
r160467 r160525 77 77 78 78 dispatch_async(dispatch_get_main_queue(), ^{ 79 if ( protector->hasHandle()) {79 if (!protector->hasHandle()) { 80 80 continueWillSendRequest(nullptr); 81 81 return; … … 104 104 105 105 dispatch_async(dispatch_get_main_queue(), ^{ 106 if ( protector->hasHandle()) {106 if (!protector->hasHandle()) { 107 107 continueDidReceiveResponse(); 108 108 return; … … 134 134 135 135 dispatch_async(dispatch_get_main_queue(), ^{ 136 if ( !protector->hasHandle()) {136 if (protector->hasHandle()) { 137 137 LOG(Network, "CFNet - ResourceHandleCFURLConnectionDelegateWithOperationQueue::didReceiveData(handle=%p) (%s)", m_handle, m_handle->firstRequest().url().string().utf8().data()); 138 138 … … 148 148 RefPtr<ResourceHandleCFURLConnectionDelegateWithOperationQueue> protector(this); 149 149 dispatch_async(dispatch_get_main_queue(), ^{ 150 if ( protector->hasHandle())150 if (!protector->hasHandle()) 151 151 return; 152 152 … … 162 162 CFRetain(error); 163 163 dispatch_async(dispatch_get_main_queue(), ^{ 164 if ( !protector->hasHandle()) {164 if (protector->hasHandle()) { 165 165 LOG(Network, "CFNet - ResourceHandleCFURLConnectionDelegateWithOperationQueue::didFail(handle=%p) (%s)", m_handle, m_handle->firstRequest().url().string().utf8().data()); 166 166 … … 177 177 178 178 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 192 void ResourceHandleCFURLConnectionDelegateWithOperationQueue::didReceiveChallenge(CFURLAuthChallengeRef challenge) 193 { 194 RefPtr<ResourceHandleCFURLConnectionDelegateWithOperationQueue> protector(this); 195 CFRetain(challenge); 196 dispatch_async(dispatch_get_main_queue(), ^{ 179 197 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()) {198 198 LOG(Network, "CFNet - ResourceHandleCFURLConnectionDelegateWithOperationQueue::didReceiveChallenge(handle=%p) (%s)", m_handle, m_handle->firstRequest().url().string().utf8().data()); 199 199 … … 209 209 RefPtr<ResourceHandleCFURLConnectionDelegateWithOperationQueue> protector(this); 210 210 dispatch_async(dispatch_get_main_queue(), ^{ 211 if ( protector->hasHandle())211 if (!protector->hasHandle()) 212 212 return; 213 213 … … 223 223 224 224 dispatch_async(dispatch_get_main_queue(), ^{ 225 if ( protector->hasHandle()) {225 if (!protector->hasHandle()) { 226 226 continueShouldUseCredentialStorage(false); 227 227 return; … … 242 242 243 243 dispatch_async(dispatch_get_main_queue(), ^{ 244 if ( protector->hasHandle()) {244 if (!protector->hasHandle()) { 245 245 continueCanAuthenticateAgainstProtectionSpace(false); 246 246 return; … … 270 270 CFRetain(dataArray); 271 271 dispatch_async(dispatch_get_main_queue(), ^{ 272 if ( !protector->hasHandle()) {272 if (protector->hasHandle()) { 273 273 LOG(Network, "CFNet - ResourceHandleCFURLConnectionDelegateWithOperationQueue::didSendBodyData(handle=%p) (%s)", m_handle, m_handle->firstRequest().url().string().utf8().data()); 274 274
Note: See TracChangeset
for help on using the changeset viewer.