Bug 1287602 - CacheFile::GetChunk() is unused. r=michal
authorAndrew McCreight <continuation@gmail.com>
Wed, 20 Jul 2016 15:18:59 -0700
changeset 331003 257f417d40666e220babef29065df87d9c711e9d
parent 331002 bf7983226fbee0753076dee69ae308e29560324e
child 331004 31501b1f9b2d38c122eae611f8b9f5b88969e3ef
push id9858
push userjlund@mozilla.com
push dateMon, 01 Aug 2016 14:37:10 +0000
treeherdermozilla-aurora@203106ef6cb6 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersmichal
bugs1287602
milestone50.0a1
Bug 1287602 - CacheFile::GetChunk() is unused. r=michal
netwerk/cache2/CacheFile.cpp
netwerk/cache2/CacheFile.h
--- a/netwerk/cache2/CacheFile.cpp
+++ b/netwerk/cache2/CacheFile.cpp
@@ -1082,24 +1082,16 @@ void
 CacheFile::ReleaseOutsideLock(RefPtr<nsISupports> aObject)
 {
   AssertOwnsLock();
 
   mObjsToRelease.AppendElement(Move(aObject));
 }
 
 nsresult
-CacheFile::GetChunk(uint32_t aIndex, ECallerType aCaller,
-                    CacheFileChunkListener *aCallback, CacheFileChunk **_retval)
-{
-  CacheFileAutoLock lock(this);
-  return GetChunkLocked(aIndex, aCaller, aCallback, _retval);
-}
-
-nsresult
 CacheFile::GetChunkLocked(uint32_t aIndex, ECallerType aCaller,
                           CacheFileChunkListener *aCallback,
                           CacheFileChunk **_retval)
 {
   AssertOwnsLock();
 
   LOG(("CacheFile::GetChunkLocked() [this=%p, idx=%u, caller=%d, listener=%p]",
        this, aIndex, aCaller, aCallback));
--- a/netwerk/cache2/CacheFile.h
+++ b/netwerk/cache2/CacheFile.h
@@ -131,19 +131,16 @@ private:
   enum ECallerType {
     READER    = 0,
     WRITER    = 1,
     PRELOADER = 2
   };
 
   nsresult DoomLocked(CacheFileListener *aCallback);
 
-  nsresult GetChunk(uint32_t aIndex, ECallerType aCaller,
-                    CacheFileChunkListener *aCallback,
-                    CacheFileChunk **_retval);
   nsresult GetChunkLocked(uint32_t aIndex, ECallerType aCaller,
                           CacheFileChunkListener *aCallback,
                           CacheFileChunk **_retval);
 
   void     PreloadChunks(uint32_t aIndex);
   bool     ShouldCacheChunk(uint32_t aIndex);
   bool     MustKeepCachedChunk(uint32_t aIndex);