operations: write debug message when hashes could not be checked

This commit is contained in:
Ole Schütt 2020-01-05 15:15:30 +01:00 committed by Nick Craig-Wood
parent b7019a91c2
commit f263828edc

View file

@ -779,10 +779,12 @@ func (c *checkMarch) Match(ctx context.Context, dst, src fs.DirEntry) (recurse b
atomic.AddInt32(&c.differences, 1) atomic.AddInt32(&c.differences, 1)
} else { } else {
atomic.AddInt32(&c.matches, 1) atomic.AddInt32(&c.matches, 1)
fs.Debugf(dstX, "OK") if noHash {
} atomic.AddInt32(&c.noHashes, 1)
if noHash { fs.Debugf(dstX, "OK - could not check hash")
atomic.AddInt32(&c.noHashes, 1) } else {
fs.Debugf(dstX, "OK")
}
} }
} else { } else {
err := errors.Errorf("is file on %v but directory on %v", c.fsrc, c.fdst) err := errors.Errorf("is file on %v but directory on %v", c.fsrc, c.fdst)