Fixed a crashing bug when showing the history of excluded files

This commit is contained in:
Gilbert Chen
2018-05-30 12:05:40 -04:00
parent e03cd2a880
commit 0e585e4be4

View File

@@ -1490,7 +1490,7 @@ func (manager *SnapshotManager) ShowHistory(top string, snapshotID string, revis
} }
if showLocalHash { if showLocalHash {
localFile.Hash = manager.config.ComputeFileHash(joinPath(top, filePath), make([]byte, 32*1024)) localFile.Hash = manager.config.ComputeFileHash(joinPath(top, filePath), make([]byte, 32*1024))
if lastVersion.Hash != localFile.Hash { if lastVersion == nil || lastVersion.Hash != localFile.Hash {
modifiedFlag = "*" modifiedFlag = "*"
} }
} }