Do not crash if a null filename is given

This commit is contained in:
Michael Becker 2014-07-05 19:12:28 -04:00
parent 84b4798eaf
commit 23c7972f0d

View File

@ -278,10 +278,8 @@ namespace UniversalEditor
}
public bool MatchesFile(string FileName, System.IO.Stream FileData)
{
if (FileName != null)
{
FileName = System.IO.Path.GetFileName(FileName);
}
if (FileName == null) return false;
if (System.IO.File.Exists(FileName)) FileName = System.IO.Path.GetFileName(FileName);
switch (mvarHintComparison)
{