Fix access mode for new entries. Not part of the build.

git-svn-id: svn://10.0.0.236/trunk@88201 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
gordon%netscape.com 2001-02-28 22:39:07 +00:00
parent 86d7e6bcb3
commit c08d7ab02c

View File

@ -152,14 +152,11 @@ nsCacheEntry::CommonOpen(nsCacheRequest * request, nsCacheAccessMode *accessGran
if (!IsInitialized()) {
// brand new, unbound entry
NS_ASSERTION(request->mAccessRequested & nsICache::ACCESS_WRITE,
"new cache entry for READ-ONLY request");
*accessGranted = request->mAccessRequested & nsICache::ACCESS_WRITE;
NS_ASSERTION(*accessGranted, "new cache entry for READ-ONLY request");
if (request->mStreamBased) MarkStreamBased();
mFetchCount = 1;
MarkInitialized();
// why shouldn't the initial entry allow writing?
//*accessGranted = request->mAccessRequested & ~nsICache::ACCESS_WRITE;
*accessGranted = request->mAccessRequested;
return rv;
}