зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1371333 - Remove unused CacheTokenLastFetched from CacheInfoChannel. r=valentin
This commit is contained in:
Родитель
7a08464871
Коммит
542817ed5d
|
@ -18,15 +18,6 @@ interface nsICacheInfoChannel : nsISupports
|
|||
*/
|
||||
readonly attribute int32_t cacheTokenFetchCount;
|
||||
|
||||
/**
|
||||
* Get the last time the cache entry was opened from cache token. This
|
||||
* attribute is equivalent to nsICachingChannel.cacheToken.lastFetched.
|
||||
*
|
||||
* @throws NS_ERROR_NOT_AVAILABLE if the cache entry or the alternate data
|
||||
* cache entry cannot be read.
|
||||
*/
|
||||
readonly attribute uint32_t cacheTokenLastFetched;
|
||||
|
||||
/**
|
||||
* Get expiration time from cache token. This attribute is equivalent to
|
||||
* nsICachingChannel.cacheToken.expirationTime.
|
||||
|
|
|
@ -162,7 +162,6 @@ HttpChannelChild::HttpChannelChild()
|
|||
, mCacheEntryAvailable(false)
|
||||
, mAltDataCacheEntryAvailable(false)
|
||||
, mCacheFetchCount(0)
|
||||
, mCacheLastFetched(0)
|
||||
, mCacheExpirationTime(nsICacheEntry::NO_EXPIRATION_TIME)
|
||||
, mSendResumeAt(false)
|
||||
, mDeletingChannelSent(false)
|
||||
|
@ -396,7 +395,6 @@ class StartRequestEvent : public NeckoTargetChannelEvent<HttpChannelChild>
|
|||
const bool& aIsFromCache,
|
||||
const bool& aCacheEntryAvailable,
|
||||
const int32_t& aCacheFetchCount,
|
||||
const uint32_t& aCacheLastFetched,
|
||||
const uint32_t& aCacheExpirationTime,
|
||||
const nsCString& aCachedCharset,
|
||||
const nsCString& aSecurityInfoSerialization,
|
||||
|
@ -413,7 +411,6 @@ class StartRequestEvent : public NeckoTargetChannelEvent<HttpChannelChild>
|
|||
, mIsFromCache(aIsFromCache)
|
||||
, mCacheEntryAvailable(aCacheEntryAvailable)
|
||||
, mCacheFetchCount(aCacheFetchCount)
|
||||
, mCacheLastFetched(aCacheLastFetched)
|
||||
, mCacheExpirationTime(aCacheExpirationTime)
|
||||
, mCachedCharset(aCachedCharset)
|
||||
, mSecurityInfoSerialization(aSecurityInfoSerialization)
|
||||
|
@ -429,8 +426,7 @@ class StartRequestEvent : public NeckoTargetChannelEvent<HttpChannelChild>
|
|||
LOG(("StartRequestEvent [this=%p]\n", mChild));
|
||||
mChild->OnStartRequest(mChannelStatus, mResponseHead, mUseResponseHead,
|
||||
mRequestHeaders, mIsFromCache, mCacheEntryAvailable,
|
||||
mCacheFetchCount, mCacheLastFetched,
|
||||
mCacheExpirationTime, mCachedCharset,
|
||||
mCacheFetchCount, mCacheExpirationTime, mCachedCharset,
|
||||
mSecurityInfoSerialization, mSelfAddr, mPeerAddr,
|
||||
mCacheKey, mAltDataType, mAltDataLen);
|
||||
}
|
||||
|
@ -443,7 +439,6 @@ class StartRequestEvent : public NeckoTargetChannelEvent<HttpChannelChild>
|
|||
bool mIsFromCache;
|
||||
bool mCacheEntryAvailable;
|
||||
int32_t mCacheFetchCount;
|
||||
uint32_t mCacheLastFetched;
|
||||
uint32_t mCacheExpirationTime;
|
||||
nsCString mCachedCharset;
|
||||
nsCString mSecurityInfoSerialization;
|
||||
|
@ -462,7 +457,6 @@ HttpChannelChild::RecvOnStartRequest(const nsresult& channelStatus,
|
|||
const bool& isFromCache,
|
||||
const bool& cacheEntryAvailable,
|
||||
const int32_t& cacheFetchCount,
|
||||
const uint32_t& cacheLastFetched,
|
||||
const uint32_t& cacheExpirationTime,
|
||||
const nsCString& cachedCharset,
|
||||
const nsCString& securityInfoSerialization,
|
||||
|
@ -487,7 +481,7 @@ HttpChannelChild::RecvOnStartRequest(const nsresult& channelStatus,
|
|||
mEventQ->RunOrEnqueue(new StartRequestEvent(this, channelStatus, responseHead,
|
||||
useResponseHead, requestHeaders,
|
||||
isFromCache, cacheEntryAvailable,
|
||||
cacheFetchCount, cacheLastFetched,
|
||||
cacheFetchCount,
|
||||
cacheExpirationTime, cachedCharset,
|
||||
securityInfoSerialization,
|
||||
selfAddr, peerAddr, cacheKey,
|
||||
|
@ -523,7 +517,6 @@ HttpChannelChild::OnStartRequest(const nsresult& channelStatus,
|
|||
const bool& isFromCache,
|
||||
const bool& cacheEntryAvailable,
|
||||
const int32_t& cacheFetchCount,
|
||||
const uint32_t& cacheLastFetched,
|
||||
const uint32_t& cacheExpirationTime,
|
||||
const nsCString& cachedCharset,
|
||||
const nsCString& securityInfoSerialization,
|
||||
|
@ -557,7 +550,6 @@ HttpChannelChild::OnStartRequest(const nsresult& channelStatus,
|
|||
mIsFromCache = isFromCache;
|
||||
mCacheEntryAvailable = cacheEntryAvailable;
|
||||
mCacheFetchCount = cacheFetchCount;
|
||||
mCacheLastFetched = cacheLastFetched;
|
||||
mCacheExpirationTime = cacheExpirationTime;
|
||||
mCachedCharset = cachedCharset;
|
||||
mSelfAddr = selfAddr;
|
||||
|
@ -2775,18 +2767,6 @@ HttpChannelChild::GetCacheTokenFetchCount(int32_t *_retval)
|
|||
return NS_OK;
|
||||
}
|
||||
|
||||
NS_IMETHODIMP
|
||||
HttpChannelChild::GetCacheTokenLastFetched(uint32_t *_retval)
|
||||
{
|
||||
NS_ENSURE_ARG_POINTER(_retval);
|
||||
if (!mCacheEntryAvailable && !mAltDataCacheEntryAvailable) {
|
||||
return NS_ERROR_NOT_AVAILABLE;
|
||||
}
|
||||
|
||||
*_retval = mCacheLastFetched;
|
||||
return NS_OK;
|
||||
}
|
||||
|
||||
NS_IMETHODIMP
|
||||
HttpChannelChild::GetCacheTokenExpirationTime(uint32_t *_retval)
|
||||
{
|
||||
|
|
|
@ -133,7 +133,6 @@ protected:
|
|||
const bool& isFromCache,
|
||||
const bool& cacheEntryAvailable,
|
||||
const int32_t& cacheFetchCount,
|
||||
const uint32_t& cacheLastFetched,
|
||||
const uint32_t& cacheExpirationTime,
|
||||
const nsCString& cachedCharset,
|
||||
const nsCString& securityInfoSerialization,
|
||||
|
@ -277,7 +276,6 @@ private:
|
|||
bool mCacheEntryAvailable;
|
||||
bool mAltDataCacheEntryAvailable;
|
||||
int32_t mCacheFetchCount;
|
||||
uint32_t mCacheLastFetched;
|
||||
uint32_t mCacheExpirationTime;
|
||||
nsCString mCachedCharset;
|
||||
|
||||
|
@ -376,7 +374,6 @@ private:
|
|||
const bool& isFromCache,
|
||||
const bool& cacheEntryAvailable,
|
||||
const int32_t& cacheFetchCount,
|
||||
const uint32_t& cacheLastFetched,
|
||||
const uint32_t& cacheExpirationTime,
|
||||
const nsCString& cachedCharset,
|
||||
const nsCString& securityInfoSerialization,
|
||||
|
|
|
@ -1417,8 +1417,6 @@ HttpChannelParent::OnStartRequest(nsIRequest *aRequest, nsISupports *aContext)
|
|||
chan->IsFromCache(&isFromCache);
|
||||
int32_t fetchCount = 0;
|
||||
chan->GetCacheTokenFetchCount(&fetchCount);
|
||||
uint32_t lastFetchedTime = 0;
|
||||
chan->GetCacheTokenLastFetched(&lastFetchedTime);
|
||||
uint32_t expirationTime = nsICacheEntry::NO_EXPIRATION_TIME;
|
||||
chan->GetCacheTokenExpirationTime(&expirationTime);
|
||||
nsCString cachedCharset;
|
||||
|
@ -1489,7 +1487,7 @@ HttpChannelParent::OnStartRequest(nsIRequest *aRequest, nsISupports *aContext)
|
|||
requestHead->Headers(),
|
||||
isFromCache,
|
||||
mCacheEntry ? true : false,
|
||||
fetchCount, lastFetchedTime, expirationTime,
|
||||
fetchCount, expirationTime,
|
||||
cachedCharset, secInfoSerialization,
|
||||
chan->GetSelfAddr(), chan->GetPeerAddr(),
|
||||
redirectCount,
|
||||
|
|
|
@ -99,7 +99,6 @@ child:
|
|||
bool isFromCache,
|
||||
bool cacheEntryAvailable,
|
||||
int32_t cacheFetchCount,
|
||||
uint32_t cacheLastFetched,
|
||||
uint32_t cacheExpirationTime,
|
||||
nsCString cachedCharset,
|
||||
nsCString securityInfoSerialization,
|
||||
|
|
|
@ -7940,18 +7940,6 @@ nsHttpChannel::GetCacheTokenFetchCount(int32_t *_retval)
|
|||
return cacheEntry->GetFetchCount(_retval);
|
||||
}
|
||||
|
||||
NS_IMETHODIMP
|
||||
nsHttpChannel::GetCacheTokenLastFetched(uint32_t *_retval)
|
||||
{
|
||||
NS_ENSURE_ARG_POINTER(_retval);
|
||||
nsCOMPtr<nsICacheEntry> cacheEntry = mCacheEntry ? mCacheEntry : mAltDataCacheEntry;
|
||||
if (!cacheEntry) {
|
||||
return NS_ERROR_NOT_AVAILABLE;
|
||||
}
|
||||
|
||||
return cacheEntry->GetLastFetched(_retval);
|
||||
}
|
||||
|
||||
NS_IMETHODIMP
|
||||
nsHttpChannel::GetCacheTokenExpirationTime(uint32_t *_retval)
|
||||
{
|
||||
|
|
Загрузка…
Ссылка в новой задаче