mirror of
https://github.com/jkl1337/duplicacy.git
synced 2026-01-03 12:14:39 -06:00
Fixed #83: don't pass unchanged files to the chunk downloader
This commit is contained in:
@@ -749,6 +749,7 @@ func (manager *BackupManager) Restore(top string, revision int, inPlace bool, qu
|
|||||||
i := 0
|
i := 0
|
||||||
for _, entry := range remoteSnapshot.Files {
|
for _, entry := range remoteSnapshot.Files {
|
||||||
|
|
||||||
|
skipped := false
|
||||||
// Find local files that don't exist in the remote snapshot
|
// Find local files that don't exist in the remote snapshot
|
||||||
for i < len(localSnapshot.Files) {
|
for i < len(localSnapshot.Files) {
|
||||||
local := localSnapshot.Files[i]
|
local := localSnapshot.Files[i]
|
||||||
@@ -760,11 +761,18 @@ func (manager *BackupManager) Restore(top string, revision int, inPlace bool, qu
|
|||||||
} else {
|
} else {
|
||||||
if compare == 0 {
|
if compare == 0 {
|
||||||
i++
|
i++
|
||||||
|
if quickMode && local.IsSameAs(entry) {
|
||||||
|
skipped = true
|
||||||
|
}
|
||||||
}
|
}
|
||||||
break
|
break
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if skipped {
|
||||||
|
continue
|
||||||
|
}
|
||||||
|
|
||||||
fullPath := joinPath(top, entry.Path)
|
fullPath := joinPath(top, entry.Path)
|
||||||
if entry.IsLink() {
|
if entry.IsLink() {
|
||||||
stat, err := os.Lstat(fullPath)
|
stat, err := os.Lstat(fullPath)
|
||||||
|
|||||||
Reference in New Issue
Block a user