Skip to content

Commit

Permalink
remove some tabs
Browse files Browse the repository at this point in the history
  • Loading branch information
sarbian committed Dec 31, 2015
1 parent 14f095b commit 93181c8
Showing 1 changed file with 29 additions and 29 deletions.
58 changes: 29 additions & 29 deletions moduleManager.cs
Original file line number Diff line number Diff line change
Expand Up @@ -914,33 +914,33 @@ static bool checkValues(ConfigNode node)

private string FileSHA(string filename)
{
try
{
if (File.Exists(filename))
{
System.Security.Cryptography.SHA256 sha = System.Security.Cryptography.SHA256.Create();

byte[] data = null;
using (FileStream fs = File.Open(filename, FileMode.Open, FileAccess.Read))
{
data = sha.ComputeHash(fs);
}

string hashedValue = string.Empty;

foreach (byte b in data)
{
hashedValue += String.Format("{0,2:x2}", b);
}

return hashedValue;
}
}
catch (Exception e)
{
log("Exception hashing file " + filename + "\n" + e.ToString());
return "0";
}
try
{
if (File.Exists(filename))
{
System.Security.Cryptography.SHA256 sha = System.Security.Cryptography.SHA256.Create();

byte[] data = null;
using (FileStream fs = File.Open(filename, FileMode.Open, FileAccess.Read))
{
data = sha.ComputeHash(fs);
}

string hashedValue = string.Empty;

foreach (byte b in data)
{
hashedValue += String.Format("{0,2:x2}", b);
}

return hashedValue;
}
}
catch (Exception e)
{
log("Exception hashing file " + filename + "\n" + e.ToString());
return "0";
}
return "0";
}

Expand Down Expand Up @@ -2180,8 +2180,8 @@ private static string RecurseVariableSearch(string path, ConfigNode currentNode)
string[] split = value.Split(sep);
if (splitIdx < split.Length)
value = split[splitIdx];
else
value = "";
else
value = "";
}
return value;
}
Expand Down

0 comments on commit 93181c8

Please sign in to comment.