[iOS][Signin] Fixing crash related to the token cache.
When a token is requested, HasCacheEntry() is called in StartCacheLookupRequest(). This call can potentially remove the cache entry. Therefore when getting the cache entry right after, it would be not available anymore. HasCacheEntry() method should never exist, since there is no warranty that the same cache entry would be returned by GetCacheEntry() on the next line of code. To solve the problem, StartCacheLookupRequest() is renamed to InformConsumerWithCacheEntry(), and only GetCacheEntry() is used. Bug: 791695 Change-Id: Ie22c520cb0f2e2feec84781908b33ba2d0e791e5 Reviewed-on: https://chromium-review.googlesource.com/817200Reviewed-by:Mihai Sardarescu <msarda@chromium.org> Commit-Queue: Jérôme Lebel <jlebel@chromium.org> Cr-Commit-Position: refs/heads/master@{#523399}
Showing
Please register or sign in to comment