Fixed a problem with long paths
This commit is contained in:
@@ -154,7 +154,7 @@ namespace Duplicati.Library.Main.Database
|
||||
if (filecount != foundfiles)
|
||||
{
|
||||
var oldlen = maxpath.Length;
|
||||
maxpath = System.IO.Path.GetDirectoryName(maxpath);
|
||||
maxpath = Library.Snapshots.SnapshotUtility.SystemIO.PathGetDirectoryName(maxpath);
|
||||
if (string.IsNullOrWhiteSpace(maxpath) || maxpath.Length == oldlen)
|
||||
maxpath = "";
|
||||
}
|
||||
|
||||
@@ -197,7 +197,7 @@ namespace Duplicati.Library.Main.Database
|
||||
if (filecount != foundfiles)
|
||||
{
|
||||
var oldlen = maxpath.Length;
|
||||
maxpath = System.IO.Path.GetDirectoryName(maxpath);
|
||||
maxpath = Duplicati.Library.Snapshots.SnapshotUtility.SystemIO.PathGetDirectoryName(maxpath);
|
||||
if (string.IsNullOrWhiteSpace(maxpath) || maxpath.Length == oldlen)
|
||||
maxpath = "";
|
||||
}
|
||||
|
||||
@@ -41,5 +41,13 @@ namespace Duplicati.Library.Snapshots
|
||||
else
|
||||
return new WindowsSnapshot(folders, options);
|
||||
}
|
||||
|
||||
public static ISystemIO SystemIO
|
||||
{
|
||||
get
|
||||
{
|
||||
return Utility.Utility.IsClientLinux ? (ISystemIO)new SystemIOLinux() : (ISystemIO)new SystemIOWindows();
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user