diff options
Diffstat (limited to 'OpenSim/Services')
-rw-r--r-- | OpenSim/Services/FSAssetService/FSAssetService.cs | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/OpenSim/Services/FSAssetService/FSAssetService.cs b/OpenSim/Services/FSAssetService/FSAssetService.cs index 028dd01..2fb3e6c 100644 --- a/OpenSim/Services/FSAssetService/FSAssetService.cs +++ b/OpenSim/Services/FSAssetService/FSAssetService.cs | |||
@@ -52,7 +52,6 @@ namespace OpenSim.Services.FSAssetService | |||
52 | private static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType); | 52 | private static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType); |
53 | 53 | ||
54 | static System.Text.ASCIIEncoding enc = new System.Text.ASCIIEncoding(); | 54 | static System.Text.ASCIIEncoding enc = new System.Text.ASCIIEncoding(); |
55 | static SHA256CryptoServiceProvider SHA256 = new SHA256CryptoServiceProvider(); | ||
56 | 55 | ||
57 | static byte[] ToCString(string s) | 56 | static byte[] ToCString(string s) |
58 | { | 57 | { |
@@ -357,7 +356,9 @@ namespace OpenSim.Services.FSAssetService | |||
357 | 356 | ||
358 | string GetSHA256Hash(byte[] data) | 357 | string GetSHA256Hash(byte[] data) |
359 | { | 358 | { |
360 | byte[] hash = SHA256.ComputeHash(data); | 359 | byte[] hash; |
360 | using (SHA256CryptoServiceProvider SHA256 = new SHA256CryptoServiceProvider()) | ||
361 | hash = SHA256.ComputeHash(data); | ||
361 | 362 | ||
362 | return BitConverter.ToString(hash).Replace("-", String.Empty); | 363 | return BitConverter.ToString(hash).Replace("-", String.Empty); |
363 | } | 364 | } |