Changeset 254588 in webkit
- Timestamp:
- Jan 15, 2020, 11:14:42 AM (7 years ago)
- Location:
- branches/safari-609-branch/Source/WebKit
- Files:
-
- 2 edited
-
ChangeLog (modified) (1 diff)
-
NetworkProcess/cocoa/NetworkSessionCocoa.mm (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
branches/safari-609-branch/Source/WebKit/ChangeLog
r254587 r254588 1 2020-01-14 Alan Coon <alancoon@apple.com> 2 3 Cherry-pick r254092. rdar://problem/58552872 4 5 NetworkSessionCocoa::isolatedSession should not use iterator after mutating m_isolatedSessions 6 https://bugs.webkit.org/show_bug.cgi?id=205824 7 <rdar://problem/55107625> 8 9 Patch by Alex Christensen <achristensen@webkit.org> on 2020-01-06 10 Reviewed by Chris Dumez. 11 12 Classic iterator use after mutating iterated container was causing crashes by returning a null SessionWrapper& 13 This was introduced in r252185 or r248640. 14 15 * NetworkProcess/cocoa/NetworkSessionCocoa.mm: 16 (WebKit::NetworkSessionCocoa::isolatedSession): 17 18 git-svn-id: https://svn.webkit.org/repository/webkit/trunk@254092 268f45cc-cd09-0410-ab3c-d52691b4dbfc 19 20 2020-01-06 Alex Christensen <achristensen@webkit.org> 21 22 NetworkSessionCocoa::isolatedSession should not use iterator after mutating m_isolatedSessions 23 https://bugs.webkit.org/show_bug.cgi?id=205824 24 <rdar://problem/55107625> 25 26 Reviewed by Chris Dumez. 27 28 Classic iterator use after mutating iterated container was causing crashes by returning a null SessionWrapper& 29 This was introduced in r252185 or r248640. 30 31 * NetworkProcess/cocoa/NetworkSessionCocoa.mm: 32 (WebKit::NetworkSessionCocoa::isolatedSession): 33 1 34 2020-01-14 Alan Coon <alancoon@apple.com> 2 35 -
branches/safari-609-branch/Source/WebKit/NetworkProcess/cocoa/NetworkSessionCocoa.mm
r253642 r254588 1195 1195 entry->lastUsed = WallTime::now(); 1196 1196 1197 auto& sessionWrapper = [&] (auto storedCredentialsPolicy) -> SessionWrapper& { 1198 switch (storedCredentialsPolicy) { 1199 case WebCore::StoredCredentialsPolicy::Use: 1200 LOG(NetworkSession, "Using isolated NSURLSession with credential storage."); 1201 return entry->sessionWithCredentialStorage; 1202 case WebCore::StoredCredentialsPolicy::DoNotUse: 1203 LOG(NetworkSession, "Using isolated NSURLSession without credential storage."); 1204 return entry->sessionWithoutCredentialStorage; 1205 case WebCore::StoredCredentialsPolicy::EphemeralStateless: 1206 if (!m_ephemeralStatelessSession.session) 1207 initializeEphemeralStatelessSession(); 1208 return m_ephemeralStatelessSession; 1209 } 1210 } (storedCredentialsPolicy); 1211 1197 1212 if (m_isolatedSessions.size() > maxNumberOfIsolatedSessions) { 1198 1213 WebCore::RegistrableDomain keyToRemove; … … 1211 1226 RELEASE_ASSERT(m_isolatedSessions.size() <= maxNumberOfIsolatedSessions); 1212 1227 1213 switch (storedCredentialsPolicy) { 1214 case WebCore::StoredCredentialsPolicy::Use: 1215 LOG(NetworkSession, "Using isolated NSURLSession with credential storage."); 1216 return entry->sessionWithCredentialStorage; 1217 case WebCore::StoredCredentialsPolicy::DoNotUse: 1218 LOG(NetworkSession, "Using isolated NSURLSession without credential storage."); 1219 return entry->sessionWithoutCredentialStorage; 1220 case WebCore::StoredCredentialsPolicy::EphemeralStateless: 1221 if (!m_ephemeralStatelessSession.session) 1222 initializeEphemeralStatelessSession(); 1223 return m_ephemeralStatelessSession; 1224 } 1228 return sessionWrapper; 1225 1229 } 1226 1230
Note:
See TracChangeset
for help on using the changeset viewer.