diff --git a/DependenciesLib/BinaryCache.cs b/DependenciesLib/BinaryCache.cs index 9112ec8e..fcc8547a 100644 --- a/DependenciesLib/BinaryCache.cs +++ b/DependenciesLib/BinaryCache.cs @@ -294,7 +294,6 @@ public BinaryCacheImpl(string ApplicationAppDataPath, int _MaxBinaryCount) { BinaryDatabase = new Dictionary(); - FilepathDatabase = new Dictionary(); BinaryDatabaseLock = new Object(); LruCache = new List(); @@ -379,7 +378,6 @@ public override void Unload() // flush the cache BinaryDatabase.Clear(); - FilepathDatabase.Clear(); } public void GetBinaryAsync(string PePath, RunWorkerCompletedEventHandler Callback = null) @@ -409,15 +407,6 @@ public override PE GetBinary(string PePath) return null; } - string Fullpath = Path.GetFullPath(PePath); - if (FilepathDatabase.ContainsKey(Fullpath)) - { - // TODO : update LRU cache - PE sShadowBinary = FilepathDatabase[Fullpath]; - sShadowBinary.Filepath = Fullpath; - return sShadowBinary; - } - string PeHash = GetBinaryHash(PePath); //Debug.WriteLine(String.Format("File {0:s} hash : {1:s} ", PePath, PeHash), "BinaryCache"); @@ -443,7 +432,6 @@ public override PE GetBinary(string PePath) LruCache.Add(PeHash); BinaryDatabase.Add(PeHash, NewShadowBinary); - FilepathDatabase.Add(Fullpath, NewShadowBinary); } } @@ -478,7 +466,6 @@ protected void UpdateLru(string PeHash) #region Members private List LruCache; private Dictionary BinaryDatabase; - private Dictionary FilepathDatabase; private Object BinaryDatabaseLock; private string BinaryCacheFolderPath;