Fix zero-length hash models incorrectly creating a unique hash

This commit is contained in:
Dean Herbert 2019-07-29 16:55:39 +09:00
parent 2318402292
commit cb17007fa7
1 changed files with 1 additions and 1 deletions

View File

@ -253,7 +253,7 @@ private string computeHash(ArchiveReader reader)
using (Stream s = reader.GetStream(file))
s.CopyTo(hashable);
return hashable.ComputeSHA2Hash();
return hashable.Length > 0 ? hashable.ComputeSHA2Hash() : null;
}
/// <summary>