Index: net/http/http_cache.cc |
diff --git a/net/http/http_cache.cc b/net/http/http_cache.cc |
index 27c591d44501dfe84e4cb46e01514692b7a013af..19c7c86f91e6c832caf0fcf8859f476d92b873ad 100644 |
--- a/net/http/http_cache.cc |
+++ b/net/http/http_cache.cc |
@@ -722,7 +722,10 @@ int HttpCache::OpenEntry(const std::string& key, ActiveEntry** entry, |
int HttpCache::CreateEntry(const std::string& key, ActiveEntry** entry, |
Transaction* trans) { |
- DCHECK(!FindActiveEntry(key)); |
+ if (FindActiveEntry(key)) { |
+ return ERR_CACHE_RACE; |
+ } |
+ |
WorkItem* item = new WorkItem(WI_CREATE_ENTRY, trans, entry); |
PendingOp* pending_op = GetPendingOp(key); |