windows compat
This commit is contained in:
parent
9df02b7def
commit
32cb4bcb76
1 changed files with 2 additions and 1 deletions
|
|
@ -1,3 +1,4 @@
|
|||
using System.IO;
|
||||
using System.Linq;
|
||||
using System.Security.Claims;
|
||||
using System.Text;
|
||||
|
|
@ -14,7 +15,7 @@ namespace Yavsc.Abstract.FileSystem
|
|||
public static bool IsValidYavscPath(this string path)
|
||||
{
|
||||
if (string.IsNullOrEmpty(path)) return true;
|
||||
foreach (var name in path.Split('/'))
|
||||
foreach (var name in path.Split(Path.DirectorySeparatorChar))
|
||||
{
|
||||
if (!IsValidDirectoryName(name) || name.Equals("..") || name.Equals("."))
|
||||
return false;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue