Path fixes
This commit is contained in:
@@ -221,7 +221,7 @@ private:
|
||||
else // File (cache and/or Sia operation)
|
||||
{
|
||||
// Formulate Sia path and cache path
|
||||
SString siaPath = CSiaApi::FormatToSiaPath(FilePath(FileName).RemoveFileName()); // Strip drive letter to get Sia path
|
||||
SString siaPath = CSiaApi::FormatToSiaPath(FilePath(FileName).SkipRoot()); // Strip drive letter to get Sia path
|
||||
if (siaPath.Length())
|
||||
{
|
||||
// If cache file already exists and is a directory, requested file operation isn't valid
|
||||
@@ -393,19 +393,18 @@ private:
|
||||
auto siaFileTree = _siaFileTree;
|
||||
if (siaFileTree)
|
||||
{
|
||||
SString siaQuery = CSiaApi::FormatToSiaPath(FilePath(FileName).RemoveFileName());
|
||||
SString siaQuery = CSiaApi::FormatToSiaPath(FilePath(FileName).SkipRoot());
|
||||
|
||||
FilePath cachePath;
|
||||
FilePath cachePath = GetCacheLocation();;
|
||||
FilePath rootPath = siaQuery;
|
||||
if (FilePath::DirSep == FileName)
|
||||
{
|
||||
cachePath = GetCacheLocation();
|
||||
siaQuery += L"/*.*";
|
||||
}
|
||||
else
|
||||
{
|
||||
cachePath.Append(&FileName[1]);
|
||||
if (::GetFileAttributes(&cachePath[0]) & FILE_ATTRIBUTE_DIRECTORY)
|
||||
if (cachePath.IsDirectory())
|
||||
{
|
||||
siaQuery += L"/*.*";
|
||||
}
|
||||
|
Reference in New Issue
Block a user