Closed bgrainger closed 9 years ago
I think Truncate
would actually be better (and should match what is implicitly happening in the current code).
Wow, nice find. That sounds like a good fix; I'd be happier taking it as a pull request if you're up for that in that I can't easily test it here, so would be glad to know that the fix actually worked!
Google Drive appears to have millisecond resolution for its file modification times, but NTFS supports nanosecond resolution. Thus
localTime.Equal(driveTime)
in upload.go:559 almost always returnsfalse
on NTFS, causing all files to go through an expensive checksum comparison.Without objection, I will open a PR solving this by rounding all times to the nearest millisecond (i.e.,
stat.ModTime().UTC().Round(time.Millisecond)
).