Index: net/http/http_cache.cc |
diff --git a/net/http/http_cache.cc b/net/http/http_cache.cc |
index 27c591d44501dfe84e4cb46e01514692b7a013af..421300ebfedd0d8b89b73b1bf31d4e7899507e66 100644 |
--- a/net/http/http_cache.cc |
+++ b/net/http/http_cache.cc |
@@ -722,7 +722,9 @@ 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); |